PlantWhenNow
← Back to Growing Guides
Companion Planting4 min readFebruary 28, 2026

Best Companion Plants for Cucumbers (Boost Yields Naturally)

Discover the best companion plants for cucumbers including beans, corn, sunflowers, and dill. Plus plants to avoid planting near cucumbers.

Cucumbers are one of those crops that responds really well to good companions and really poorly to bad ones. Get it right and you'll have more cucumbers than you know what to do with. Get it wrong and you'll spend all summer fighting pests and wondering why your plants look sad.

I've grown cucumbers next to just about everything at this point, and here's what actually makes a difference.

Best companions for cucumbers

Companion PlantWhy It WorksSpacing Notes
Beans (bush)Fix nitrogen cucumbers love; low profile doesn't shade cukesAlternate rows, 12 inches between
CornProvides light afternoon shade in hot climates; windbreakPlant corn to the west of cucumbers
SunflowersAttract pollinators; provide partial shadeNorth or west edge of cucumber bed
DillAttracts beneficial wasps that prey on cucumber beetlesScatter among cucumber plants
MarigoldsRepel aphids and beetles; attract hoverfliesBorder around cucumber bed
RadishesRepel cucumber beetles; harvest before cukes need spaceDirect sow between cucumber hills
LettuceLow ground cover; benefits from cucumber shadePlant at base of trellised cucumbers
PeasFix nitrogen; done before cucumbers peakEarly spring peas, then cucumbers take over

The dill connection

Dill deserves special attention here. It's one of the best companions for cucumbers early in the season — it attracts beneficial insects like parasitic wasps and ladybugs that prey on cucumber pests. However, there's a catch: once dill goes to seed, it can actually inhibit cucumber growth slightly.

Keep dill in check

Keep dill trimmed and harvest it regularly, or pull it once it starts flowering heavily and the cucumbers are established. That way you get the pest-fighting benefits without the late-season growth inhibition.

Plants to keep away from cucumbers

Some neighbors do more harm than good. Give these plants their own space, well away from your cucumber bed.

Keep these away — and how far
Potatoes
Compete aggressively for water and nutrients, and can spread blight to cucumbers
Aromatic herbs (sage, mint, oregano)
Strong oils can inhibit cucumber growth; keep at least 3-4 feet away
Melons and squash
Same family, share diseases and pests (powdery mildew, cucumber beetles); separate by 15-20 feet
Fennel
Allelopathic to most garden vegetables, including cucumbers

Trellising changes your companion options

If you grow cucumbers vertically on a trellis (which I strongly recommend), you open up a lot of ground-level companion planting space. The area beneath trellised cucumbers gets dappled shade — perfect for lettuce, spinach, and other greens that bolt in full sun. You effectively double your garden productivity from the same square footage.

On the east side of a cucumber trellis, plant sun-loving companions like beans and marigolds. On the shaded west side, tuck in lettuce, spinach, or cilantro.

Pollination matters

Cucumbers need pollinators — every single fruit starts as a female flower that must be pollinated. This is why pollinator-attracting companions like borage, sunflowers, and marigolds aren't just nice to have, they directly increase your harvest. If you've ever had cucumbers that start to form but then shrivel and drop, poor pollination is almost always the cause.

Find the perfect planting dates for cucumbers in your zone with our planting calendar tool.

Try our Free Vegetable Planting Calendar by ZIP Code

Enter your ZIP code for a free, personalized planting calendar. See when to start seeds, transplant, and harvest 45+ vegetables, herbs, and flowers based on your USDA hardiness zone and frost dates.

Open Planting Calendar