Companion Plants for Dill: 7 That Attract Beneficial Insects (And 3 to Avoid)
Grow these 7 plants near dill to activate its insect-attracting power — and keep these 3 away. Backed by university extension research.
Most gardeners grow dill for the kitchen. But a dill plant in full flower is doing something far more useful than flavoring a pickle brine — it is running a refueling station for some of the garden’s most effective pest killers.
Dill (Anethum graveolens) belongs to the Apiaceae family, the same umbrella-flowered group as carrots, cilantro, and fennel. That flat-topped flower head is not just decorative. It is one of the few flower structures that parasitoid wasps — tiny predators that destroy aphids and caterpillar pests from the inside out — can actually access. According to the University of Maryland Extension, the best nectar sources for these wasps are “flowers with wide or shallow corollas,” and the carrot and cabbage families top that list.

That’s the case for what dill gives to its neighbors. But dill also needs the right neighbors to give back — plants that shelter its fragile hollow stems, protect it from aphids, and fill the gaps in the garden calendar that dill’s bolt-prone nature leaves open.
Here are the seven companion plants that work best alongside dill, plus three to keep on the other side of the garden entirely.
How Dill Attracts Beneficial Insects — and Why the Flower Matters
Dill is a two-stage companion plant, and understanding the distinction changes how you use it.
Before it flowers, dill’s aromatic foliage releases terpenoid compounds that may help mask nearby crops from aphids searching for a host by scent. This is the harvest stage — the stage most home gardeners want to stay at as long as possible.
Once it flowers, the function shifts entirely. The flat yellow umbels open into a landing platform of hundreds of tiny individual florets. Parasitoid wasps — the insects that lay eggs inside aphids, caterpillar eggs, and whiteflies — need shallow nectaries they can reach with short mouthparts. Most flowers are designed for bees. Apiaceae flowers are designed, by accident, for parasitoids. University of Maryland Extension identifies the carrot family as among the best nectar sources for these wasps, and notes that “as a group they may be the single most important biological control method gardeners have.”
The catch is that you cannot harvest dill and run an insect habitat at the same time. The solution is succession sowing: start a new row every two to three weeks throughout spring, harvesting from the oldest plants while letting newer ones mature and flower at the bed edges. This keeps your kitchen supplied and your garden’s beneficial insect population continuously supported.

1. Brassicas — Dill’s Most Powerful Pairing
Plant dill alongside cabbage, broccoli, kale, or Brussels sprouts and you are combining two complementary pest defense mechanisms in the same bed.
Brassicas suffer heavily from imported cabbageworm, cabbage looper, and cabbage aphids. The parasitoid wasp genus Cotesia attacks both cabbageworm and looper caterpillars — but adult wasps need nectar, and that nectar comes from flowers like dill’s. By planting dill at the edge of your brassica bed, you give those wasps a reason to stay in the area and a food source that lets them complete their life cycles close to their prey.
The effect goes beyond wasps. A 1997 study published in Advances in Horticultural Science (Patt, Hamilton, and Lashomb) found that dill intercropped in eggplant fields significantly increased coccinellid (ladybug) populations compared to control fields. Critically, Colorado potato beetle larval survivorship was lowest in the dill-intercropped plots, and more beetle egg masses were consumed. The mechanism, according to the peer-reviewed summary in a companion planting and insect pest control analysis, was improved biological control through enhanced predator activity — not chemical deterrence.
NC State Extension specifically recommends dill as a companion for broccoli, and Penn State Extension confirms the brassica pairing as beneficial. For spacing, plant dill within 18 to 24 inches of the brassica row — beyond that, the insect-habitat effect diminishes as beneficial insects are less likely to patrol across a large gap.
2. Cucumbers — A Natural Partnership
Cucumbers and dill share a long tradition as companion plants in vegetable gardens, and NC State Extension names them together directly. The reasoning holds up under scrutiny.
Cucumbers face consistent pressure from aphids, spider mites, and cucumber beetles. Dill’s flowering stage draws in the ladybugs, hoverflies, and parasitoid wasps that target aphid colonies. Hoverfly larvae are especially useful — adults look like small bees and visit flowers for nectar, while their larvae are voracious aphid predators capable of consuming dozens per day.
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 Harvest



There is a practical timing advantage too. Dill matures faster than cucumbers and can be established and flowering by the time cucumber plants are growing vigorously and attracting their first pest populations. Sow dill at the same time as cucumber seeds, and dill will be in flower just when cucumbers need the most pest protection.
One note on spacing: avoid planting dill directly over cucumber crowns. Dill grows 18 inches to 4 feet tall and will shade cucumbers if allowed to. Plant dill on the north side of the cucumber row or at the bed edge where it will not cast shade on low-growing vines.
3. Onions and Garlic — Companions That Protect Dill
Most companion planting discussions treat dill as the helper. This one reverses the direction.
Dill is susceptible to Myzus persicae (green peach aphid) and other aphid species, particularly in hot weather. Alliums — onions, garlic, chives, and leeks — produce sulfur-based volatile organic compounds as part of their natural chemistry. According to Ben-Issa et al. (2017, Insects, published in PMC), these sulfur VOCs physically adhere to neighboring plant surfaces, masking the host’s chemical signature from aphids searching for a feeding site. The effect is strongest within 12 to 18 inches and diminishes rapidly with distance.
Planting a border of garlic or a row of bunching onions along the edges of your dill bed gives the dill some protection during its most vulnerable growth stages. Chives work especially well because they stay compact and will not compete aggressively for soil space.
There is a secondary benefit: onions and garlic also deter the carrot rust fly (Psila rosae), a pest that attacks all Apiaceae family plants — including dill. Keeping alliums nearby creates a scent barrier that makes it harder for this pest to locate its host plants by smell.
4. Asparagus, Lettuce, and Corn
Asparagus benefits from dill in the same way brassicas do: dill’s flowering umbels support parasitoid wasps and ladybugs that reduce asparagus beetle populations. The asparagus beetle (Crioceris asparagi) is the most damaging pest of established asparagus beds, and its egg and larval stages are targeted by parasitoids. Because asparagus is a permanent perennial bed, planting a strip of dill along its edge — and allowing some of it to flower each season — builds a stable population of beneficial insects right where they are needed year after year.
Lettuce pairs well with dill for a different reason: timing. Both thrive in cool weather and both struggle once summer heat arrives. In the shoulder seasons of spring and fall, dill’s aromatic foliage helps confuse aphids looking for lettuce plants. As temperatures climb, taller dill plants can provide light partial shade that slows lettuce bolting by a few days — a small but practical benefit if you are trying to extend your harvest. When planning your year-round planting schedule, treat dill and lettuce as natural companions for the spring and fall windows.
Corn offers something dill rarely gets in the open garden: wind protection. According to UMN Extension, dill’s hollow stems are easily damaged by wind. A row of corn planted to the prevailing wind side of a dill planting acts as a natural windbreak. In return, dill’s flowering umbels attract predators that help with corn pest caterpillars later in the season. Plant dill on the sheltered, leeward side of the corn row once the corn reaches knee height.
5. Tomatoes — A Partnership With a Deadline
Dill and tomatoes have a complicated relationship that almost every gardening source gets partially wrong by treating them as simply good or simply bad companions. The growth stage of the dill is the deciding factor.
Young dill planted within a tomato bed can help deter aphids and spider mites through its aromatic foliage, and it attracts hoverflies and parasitoid wasps that target tomato hornworm. Penn State Extension lists dill among the herbs that attract beneficial insects and pollinators to the garden without flagging tomatoes as incompatible.
Mature, seed-setting dill is a different matter. Once dill completes its life cycle and the plant shifts energy toward seed production, it releases allelopathic compounds that can inhibit the growth of nearby tomatoes. Gardeners who allow dill to self-seed prolifically often find that tomato plants growing within 18 inches of the dill patch show stunted growth the following season as seedlings emerge and compete aggressively.
The practical strategy: sow dill on the periphery of the tomato bed, at least 3 feet from the nearest plant. Harvest dill leaves regularly to delay flowering. If you want to let some dill go to flower for insect habitat, do so at the bed’s edge rather than between rows, and remove the plants before they set seed or immediately after seed harvest.
3 Plants to Keep Well Away from Dill
Fennel
Fennel (Foeniculum vulgare) is the most commonly cited bad companion for dill, and the reasons are well-founded. Fennel produces allelopathic compounds — primarily anethole and fenchone — from its roots and decomposing plant material that inhibit the growth and germination of many neighboring plants. UC ANR’s Master Gardener program recommends keeping fennel “separated from your vegetables, in a separate bed, or in an area several feet from other plants.”
There is also the cross-pollination question. Fennel and dill are both Apiaceae, and the conventional wisdom is that they will cross-pollinate and produce seed with inferior, muddled flavor. Some seed companies dispute whether true cross-pollination between the two species occurs. The more conservative guidance from the National Gardening Association recommends a 20-foot separation if you intend to save seed from either plant. Regardless of the cross-pollination debate, the allelopathic risk from fennel is enough to keep it in a dedicated container or isolated corner. For a deeper look at how these two herbs compare in the garden, see our guide on dill vs. fennel.
Carrots, Parsnips, and Celery
Avoid planting dill within the same bed as carrots, parsnips, or celery. All four belong to the Apiaceae family and attract the same specialist pests — most significantly the carrot rust fly (Psila rosae), which lays eggs at the base of any Apiaceae host plant. Concentrating multiple Apiaceae species in one area amplifies the attraction signal and increases the likelihood of a significant infestation.
NC State Extension notes directly that planting dill too close to a carrot crop can reduce carrot yield, and UC ANR confirms that carrots and dill “will attract the same pests” due to their shared family membership. If you grow both, keep them in separate parts of the garden with non-Apiaceae crops between them as a buffer.
Cilantro and parsley face a similar issue when planted near flowering dill — the same pests are attracted to all three. If you want to grow multiple Apiaceae herbs, stagger their flowering times or grow them in separate beds to avoid concentrating the pest-attracting signal.
Tomatoes When Dill Is Maturing
As covered in the companion section above, the incompatibility between dill and tomatoes only emerges once dill begins to set seed. Keep the two separate once dill plants move past the flowering stage, and remove or cut back dill before it produces seed near your tomato plants. This is less an absolute avoid and more a timing management issue — but treating mature seed-setting dill as a bad companion for tomatoes is the safest approach.
A Simple Layout That Makes the System Work
Companion planting with dill works best as a deliberate edge strategy rather than scattering individual plants through a bed. Plant dill in a continuous strip along one side of your brassica or cucumber row — the side that gets the most morning sun, since dill flowers open fully in direct light.
Succession sow every two to three weeks from early spring through the start of summer: the first sowing is for your kitchen, the last is for your garden’s beneficial insects. By the time you are harvesting from plants two and three, the last-sown row is coming into flower and supporting the insects that will protect late-season crops.
Good soil preparation matters too. Dill grows best in well-drained, slightly acidic soil with good organic matter content. If your beds need improvement before planting, working in compost is the most reliable fix — our guide to making compost covers the basics from kitchen scraps through to garden-ready material.
Finally, let at least one or two dill plants go to full seed each season. The self-sown seedlings that emerge the following spring will start your next season’s insect habitat with no effort from you.

Frequently Asked Questions
Can dill and cilantro grow near each other?
Yes, with one caveat: if you are saving seed from either plant, keep them at least 10 feet apart to prevent cross-pollination, which can affect flavor in subsequent generations. For kitchen use where you are not saving seed, they can share a bed without problems. Be aware that both attract the same pests (carrot family insects), so growing them in separate areas of the garden is generally better pest management.
How far away from its companion plants should dill be?
For the beneficial insect effect to work, dill needs to be within 18 to 24 inches of the plants it is protecting. Place it at bed edges or in a strip running alongside the main crop row rather than in isolated spots 3 or 4 feet away. Further than 2 feet, the parasitoid wasps and hoverflies it attracts are less likely to patrol the adjacent crop consistently.
Does dill repel pests directly, or only by attracting predators?
Both mechanisms appear to operate at different stages of the plant’s life. Young, leafy dill produces aromatic terpenoid compounds that may help mask nearby crops from aphids searching by scent. Once dill flowers, the primary mechanism is habitat provision — supporting beneficial predators and parasitoids rather than repelling pests directly. The evidence for the habitat-provision mechanism is stronger and better documented by university extension research.
Sources
- Parasitoid Wasps — University of Maryland Extension
- Herb Garden Plants: Dill — Penn State Extension
- Dill (Anethum graveolens) — NC State Extension Plant Toolbox
- Growing Dill in Home Gardens — University of Minnesota Extension
- Companion Planting in the Vegetable Garden — UC ANR Master Gardener
- Companion Planting and Insect Pest Control — IntechOpen
- Companion Plants for Aphid Pest Management — Ben-Issa et al. 2017, Insects
- Dill, Anethum graveolens — Wisconsin Horticulture Extension



