12 Companion Plants for Thyme That Repel Pests — and 3 to Avoid
Thyme’s thymol and carvacrol compounds deter cabbage worms, hornworms, and whiteflies. Discover 12 proven companion plants that thrive alongside thyme, plus 3 to keep away.
Most gardeners grow thyme in a single pot by the kitchen door and consider the job done. But thyme is one of the most useful companion plants for the vegetable garden — not because of folklore, but because of the chemistry behind its scent. Planting it strategically alongside vegetables, fruit, and other herbs gives you documented pest control, pollinator attraction, and ground cover weed suppression, all from a low-maintenance perennial that thrives on neglect. For full cultivation details, see the thyme growing guide. This guide covers 12 companion plants that work well with thyme, the mechanism that makes the combination effective, how to position it for maximum benefit, and 3 plants that will compete rather than cooperate.
Why Thyme Is Such a Powerful Garden Companion
Most herbs sit quietly in a bed and do their own thing. Thyme works for the whole garden. The reason comes down to chemistry: thyme leaves constantly release volatile compounds — primarily thymol and carvacrol — into the air around them. These aren’t just what make thyme smell good in the kitchen. For nearby pest insects, they’re deeply disorienting.

Thymol disrupts the neurological systems insects use for orientation and host-finding. Research published in Scientific Reports found that thymol alone reduced the number of male pest moths landing on pheromone sources, which means it interferes with mating communication before insects ever reach your plants. Separately, a 2005 study from Seoul National University found that carvacrol — thyme’s second major volatile compound — outperformed DEET as an insect repellent in standardized bioassays. Alpha-terpinene, another thyme compound, performed even better than carvacrol [3].
University of Minnesota Extension cites two specific studies worth knowing: an Iowa trial where thyme, onion, and nasturtium together reduced cabbage looper and imported cabbageworm damage on broccoli, and a greenhouse experiment where sage and thyme together reduced diamondback moth populations on Brussels sprouts [1]. These aren’t garden folklore. They’re controlled trials, and thyme comes out ahead of most alternatives tested.
The practical upshot: thyme works through three pathways at once. Its scent masks the odor cues that pest insects use to find host plants. Its flowers — if you let some stems bloom rather than cutting everything back — attract parasitoid wasps that lay eggs in caterpillar larvae. And as a low groundcover, it physically occupies the soil surface that weeds and soil-dwelling pests would otherwise exploit. Plant it with the right neighbors and you get all three benefits simultaneously.
12 Best Companion Plants for Thyme
Tomatoes
Thyme is one of the most recommended companions for tomatoes, and the mechanism is direct: thymol vapors disorient the tobacco/tomato hornworm (Manduca quinquemaculata), a caterpillar that can strip a tomato plant of its foliage in days. Plant common thyme (Thymus vulgaris) 12–18 inches from the base of each tomato plant. As a low grower, thyme won’t shade out the tomatoes, and it conserves soil moisture around the base without competing aggressively for water. UC ANR recommends allowing some thyme stems to flower near tomatoes specifically because the small blooms attract the parasitic wasps that target hornworm eggs [4]. If you’re growing an indeterminate variety on stakes, thyme makes an efficient living mulch underneath it.
Cabbage, Broccoli, and Brussels Sprouts
The brassica family gets the clearest research-backed benefit from thyme. The Iowa State trial showed that thyme in the bed reduced damage from both cabbage loopers (Trichoplusia ni) and imported cabbageworms (Pieris rapae) on broccoli plants [1]. The likely mechanism: monoterpenes from thyme interfere with the olfactory receptors that female Pieris butterflies use to identify brassica hosts before laying eggs. Fewer eggs laid means fewer caterpillars feeding. A greenhouse trial found that sage and thyme together reduced diamondback moth (Plutella xylostella) populations on Brussels sprouts, suggesting thyme is most effective when combined with a second aromatic herb rather than planted alone. Space thyme 12 inches from brassica transplants and allow it to spread between plants as a living mulch — this positioning keeps the volatile compounds concentrated at ground level where egg-laying adults hover.
Strawberries
Thyme and strawberries are a pairing backed by some of the most recent research available. A 2025 study from Lithuania’s Institute of Horticulture found that thyme essential oil treatment — which is 52.22% thymol — outperformed chemical fungicide treatments on strawberry yield: 18,140g per plot with thyme versus 16,695g per plot with conventional chemicals [2]. The target was Botrytis cinerea, the gray mold responsible for up to 85% of strawberry losses in wet seasons [2]. In the garden (rather than a field trial), creeping thyme (Thymus serpyllum) is the more practical choice here: its dense mat between strawberry rows suppresses weeds, moderates soil temperature, and releases thymol continuously at fruit level where botrytis spores spread. Common thyme works too, but the creeping form’s ground-hugging habit fits the row spacing better.
Carrots
Carrot fly (Psila rosae) is a persistent problem for carrot growers, and thyme is one of the most cited natural deterrents. The adult fly locates carrot foliage largely by scent — thyme’s aromatic compounds mask carrot’s volatile signature, making the row harder to find. In practice, plant thyme along the edges of carrot rows rather than between individual plants, since carrots need loose, uncompacted soil and root competition matters. Both plants share a preference for lean, well-drained conditions, which means you won’t need to make any watering compromises. If you’re growing in a raised bed, a single thyme border strip along the windward side of the carrot row gives good coverage as the scent drifts across.
Eggplant
Eggplant draws flea beetles reliably, and thyme’s volatile compounds are documented to deter flea beetle (Epitrix spp.) feeding. The combination also makes practical sense in terms of space: eggplant is a tall, upright grower that leaves plenty of open soil at its base, which thyme fills efficiently as a living mulch. Both plants prefer full sun and benefit from heat reflected off dry soil, so they won’t pull in opposite directions on watering. Plant thyme on the south-facing side of eggplant rows so it receives maximum sun without being shaded.
Rosemary
Rosemary is thyme’s most straightforward companion — identical sun requirements (full sun, 6+ hours), identical soil preferences (well-drained, pH 6.0–8.0), and similar drought tolerance once established. There’s no watering compromise needed, no competition for nutrients, and no shading issues since both stay relatively compact. Beyond compatibility, rosemary adds its own layer of pest deterrence: its camphor and borneol compounds target different pest species than thyme’s thymol, giving you a broader spectrum of olfactory disruption in the same bed. The combination is a standard recommendation in Mediterranean-style herb gardens and works equally well as a standalone herb patch or as a border alongside vegetables.
Sage
Sage pairs with thyme in the same way they pair in cooking — naturally and with complementary effects. The greenhouse diamondback moth study cited by UMN Extension used both sage and thyme, not either alone, suggesting the combination is more effective than either planted separately [1]. Sage’s 1,8-cineole compounds work on a different receptor pathway than thyme’s thymol, so together they cover more of the chemical landscape that pest insects navigate. From a growing standpoint, sage and thyme have nearly identical needs: full sun, lean alkaline-to-neutral soil, and minimal irrigation once established. Let some sage stems flower alongside thyme in late spring — the combined bloom attracts an especially dense population of beneficial insects.
Oregano
Oregano contains carvacrol as its dominant volatile compound — the same compound found in thyme — which means planting them together reinforces the same chemical barrier against pest insects rather than broadening it. That’s not a problem. Higher concentrations of carvacrol in the air around a bed may increase deterrence intensity against the pests that thymol and carvacrol both target (whiteflies, cabbage moths, certain beetles). Both herbs are drought-tolerant Mediterranean perennials that can be planted permanently in the same section of a bed without ongoing care adjustments. The main practical note: oregano spreads more aggressively than thyme, so give each plant 12–18 inches of space and trim oregano stems before they flop over and shade thyme out.




Lavender
Lavender shares thyme’s need for very well-drained, gritty soil and full sun, making it a reliable long-term companion in dry or rocky beds. Linalool — lavender’s primary volatile — targets mosquitoes and some aphid species that thyme’s compounds don’t prioritize, so the two herbs cover different pest niches. In terms of pollinator attraction, lavender is one of the strongest bee magnets available, and the bees it draws will also service thyme flowers and nearby vegetable crops. One practical consideration: lavender grows taller than thyme (12–24 inches depending on variety versus thyme’s 6–12 inches), so plant lavender to the north of thyme beds in the northern hemisphere to avoid shading.
Marigolds
Marigolds work on a different axis than thyme. Where thyme disrupts pest insects through volatile compounds in the air, marigolds produce alpha-terthienyl in their roots, which suppresses soil-dwelling nematodes and certain larvae. Planted together, thyme handles above-ground pest pressure while marigolds address what’s happening in the root zone — a complementary pairing rather than a redundant one. French marigolds (Tagetes patula) are the most researched variety for nematode suppression and stay compact enough to coexist with thyme without shading. Use them as a border companion around a thyme-and-vegetable bed rather than interplanting directly with thyme, since marigolds prefer slightly richer, moister soil than thyme tolerates.
Nasturtiums
Nasturtiums appeared alongside thyme and onion in the Iowa State broccoli trial that reduced cabbage looper damage [1], which makes this a research-backed three-way combination worth using in brassica beds. Nasturtiums serve as trap crops for aphids — the plants are highly attractive to aphids, which cluster on them in preference to nearby vegetables, making them easy to spot and knock off with water. Their open, funnel-shaped flowers also attract hoverflies (syrphid flies), whose larvae are voracious aphid predators. The main tension: nasturtiums prefer moderately moist, average soil, while thyme prefers it dry. Plant nasturtiums at the outer edge of beds where you can water them independently, with thyme closer to the vegetable row.
Roses
Thyme as a groundcover under rose bushes is an underused combination. Aphids and blackflies are among the most persistent rose pests, and thyme’s volatile compounds are cited as deterrents for both. At a practical level, thyme planted densely beneath rose canes fills the bare root zone that would otherwise be available to weeds, reduces splash-back of soil onto lower canes (which contributes to black spot spread), and doesn’t compete significantly with rose roots for moisture. Use common thyme rather than creeping thyme here — its slightly more upright habit keeps it from being smothered when rose petals drop. Water deeply but infrequently, which suits both plants.

How to Position Thyme for Maximum Effect
Where you put thyme matters almost as much as which plants it’s next to. The volatile compounds it releases are heaviest in still, warm air — which means positioning should concentrate the scent where pest insects hover and land.
For vegetable rows, plant thyme 12 inches from the row edge rather than at the perimeter of the bed. This positions the scent source at the same level where cabbage moths and whiteflies approach host plants. For raised beds, a single thyme plant every 18–24 inches along a bed edge creates a continuous aromatic border. For brassica beds specifically, interplanting thyme between individual plants (rather than just along borders) showed stronger results in the Iowa trial — the intra-row placement increases the chance that egg-laying adults encounter thymol before they reach a host.
In container gardens, a pot of thyme placed within 12 inches of a container tomato or pepper provides meaningful proximity. Wind disperses VOCs quickly, so closer is better in exposed positions. In a sheltered courtyard or against a wall, the benefit extends further. Let one or two stems flower on each thyme plant through summer: those blooms are where parasitoid wasps feed, and a fed wasp lays eggs in caterpillar larvae. Cutting everything back to a tidy shape eliminates that benefit entirely. For a broader view of timing thyme alongside cool-season and warm-season crops, see the year-round planting guide.
One Detail That Changes Everything: Lean Soil
Thyme produces more thymol when it grows in lean, low-nutrient soil. Rich, heavily amended beds encourage lush leaf growth but dilute the concentration of volatile compounds per leaf. This is the opposite of what most gardeners assume — that feeding everything well produces the best results. For companion planting purposes, thyme in a lean, gritty mix is a better pest deterrent than thyme in compost-rich vegetable soil. The practical solution is to plant thyme in its own low-fertility zone at the bed edge, rather than amending the entire bed to suit vegetables. Never fertilize thyme directly. If you need to feed neighboring vegetables, apply fertilizer away from the thyme root zone.
3 Plants to Keep Away From Thyme
Mint
Mint requires consistently moist soil — the opposite of thyme’s preference for dry, well-drained conditions. Planted together, you’ll face an impossible watering choice: water enough for mint and you’ll rot thyme roots; let it dry for thyme and mint becomes stressed and vulnerable to powdery mildew. Beyond water, mint is an aggressive runner that spreads via underground rhizomes and will encroach on thyme’s root space within a season. Keep them separated by at least 3 feet, or grow mint in a buried container to restrict spreading.
Basil
Basil and thyme are incompatible at the most fundamental level: basil needs warm, consistently moist soil and dies back at any hint of drought, while thyme actively performs better when the soil dries out between waterings. In shared beds, one plant will always suffer. Basil also prefers rich, nitrogen-boosted soil — the very conditions that reduce thyme’s thymol concentration and pest-deterrence value. In practical terms, basil belongs in the vegetable bed with tomatoes and peppers; thyme belongs at the bed edge or in its own lean, gritty zone.
Stop guessing if your garden pays.
Log what you grow and harvest — see total yield weight, estimated retail value, and season-on-season progress in one place.
→ Track My HarvestCilantro
Cilantro bolts (goes to seed) quickly in the warm, dry conditions thyme prefers. It also needs regular watering to delay bolting, which conflicts with thyme’s need for dry intervals. The two plants have overlapping root depths in containers, which increases competition for moisture in a situation where one plant’s ideal condition is the other’s stress trigger. Cilantro belongs with cool-season crops or in a shaded, moister section of the garden. If you want a herb companion that attracts beneficial insects similarly to cilantro (which has umbrella-shaped flowers that draw parasitoid wasps), use dill instead — dill tolerates somewhat drier conditions and doesn’t bolt as aggressively.

Frequently Asked Questions
Can thyme grow with peppers?
Peppers and thyme have compatible sun requirements but peppers prefer consistently moist, rich soil — the opposite of thyme’s preference. In outdoor beds, they can coexist if you plant thyme at the very edge of the pepper bed and water peppers from the opposite side. In containers, keep them separate. Some growers place a pot of thyme near pepper containers rather than planting them together, which delivers pest-deterrence proximity without forcing a soil compromise.
Does thyme actually improve the flavor of neighboring vegetables?
This claim circulates widely in companion planting guides, but there’s no controlled study confirming that thyme’s volatile compounds transfer through the air and alter the flavor of vegetables. The evidence is anecdotal. What’s documented is that thyme’s aromatic compounds influence pest behavior — which indirectly protects flavor by reducing pest damage. Apply Tier 3 confidence to any flavor-improvement claims you read: it’s a gardening heuristic, not a proven mechanism.
Should I plant common thyme or creeping thyme for companion use?
Both species contain thymol and carvacrol, so both offer pest-deterrence benefits. Common thyme (Thymus vulgaris) is the better choice for herb gardens and raised vegetable beds because its upright habit (6–12 inches) is easier to manage and keeps it from being smothered by taller companions. Creeping thyme (Thymus serpyllum) works better as a ground cover under fruit bushes and between strawberry rows, where its dense spreading mat provides both pest deterrence and effective weed suppression. For most companion planting scenarios in a vegetable garden, start with common thyme.
How many thyme plants do I need per bed?
One thyme plant per 4–6 square feet of bed provides meaningful aromatic coverage in sheltered conditions. In exposed, windy sites where volatiles disperse quickly, increase density: one plant per 2–3 square feet, or use thyme as a continuous border. In a standard 4×8-foot raised bed, three to four thyme plants positioned at intervals along one long edge gives consistent aromatic coverage across the bed without occupying prime vegetable-growing space.
Sources
- [1] University of Minnesota Extension — Companion Planting in Home Gardens
- [2] Rasiukevičiūtė et al. (2025) — Alternative Plant Protection Strategies Using Bacteria and Thyme to Improve Strawberry Yield, Plants (MDPI)
- [3] Park et al. (2005) — Monoterpenes from Thymus vulgaris as Potential Repellents, Journal of the American Mosquito Control Association
- [4] UC ANR / UC Master Gardener Program of Contra Costa — Companion Planting in the Vegetable Garden



