The Ultimate Guide to Tomato Companion Planting: 15 Best Plants & 5 to Avoid

Discover the science-backed best companion plants for tomatoes – from basil and marigolds to trap crops – plus 5 plants to avoid. Includes container tips and layouts.

Reading time: 18 min

Key Takeaways

  • Companion planting works through volatile organic compounds, physical barriers, and nutrient cycling – not folklore.
  • Basil, marigolds, and borage are your top trio for pest control and pollination in tomatoes.
  • Avoid fennel, corn, and mature dill – they compete or inhibit growth via allelopathy.
  • Use trap crops like radishes and nasturtiums to lure pests away before they reach your tomatoes.

Why Companion Planting Works: The Science Behind the Strategy

What if you could triple your tomato harvest without a single spray? That’s the promise of tomato companion planting – but only if you understand the why behind the what. Most gardeners treat companion planting as a folk tradition, grouping basil with tomatoes because “they like each other.” In my experience, the real power lies in the biochemistry. Let’s step into the lab (or rather, the garden bed) and look at the mechanisms.

Volatile Organic Compounds & Pest Confusion

Plants don’t just sit there – they talk. Through volatile organic compounds (VOCs), they send chemical signals into the air. When you interplant basil near tomatoes, the basil’s essential oils (like eugenol and linalool) mask the host-finding cues that pests like tomato hornworms and whiteflies rely on. A 2023 study in the Journal of Chemical Ecology from Wageningen University found that basil VOCs reduced whitefly landing by 62% in controlled trials. That’s not a superstition – that’s science.

Another mechanism: some companion plants release VOCs that attract natural enemies of pests. For example, dill (when young) draws parasitic wasps that prey on tomato hornworms. This is called “tritrophic interaction” – the plant calls in bodyguards. Don’t overthink it; just know that a diverse scent palette confuses pests and invites allies.

Nutrient Partitioning & Shade Ecology

Tomatoes are heavy feeders, but they don’t use every nutrient at once. Deep-rooted companions like borage and comfrey mine minerals from subsoil and deposit them on the surface via leaf litter. Meanwhile, low-growing plants like thyme or oregano form a living mulch that shades the soil, reducing water evaporation and suppressing weeds. My grandmother taught me that a crowded bed is a healthy bed – as long as the crowding is strategic. In Haarlem, I use a polyculture where basil’s shallow roots don’t compete with tomato’s deep taproot; they partition the soil profile like neighbors sharing a fence.

But not all companions play nice. Some release allelopathic chemicals that stunt neighbors. Fennel is the classic bully. Let’s define that term: Allelopathy – the release of biochemicals (e.g., fennel’s anethole) that inhibit germination or growth of nearby plants. In a companion planting context, you want plants that either avoid allelopathy or use it to your advantage (marigolds release alpha-terthienyl, which suppresses nematodes without harming tomatoes).

MechanismExample PlantTarget Pest
Repellent scent (VOCs)BasilWhiteflies, hornworms
Attract predatory insectsDill (young), parsleyAphids, hornworms
Physical barrier / ground coverThyme, oreganoWeeds, soil splash
Root exudates (allelopathic)French marigoldRoot-knot nematodes
Nutrient miningBorageImproves soil fertility

Now, once you grasp these mechanisms, the next step is obvious: choose companions that fill a specific role. Let’s move from theory to practice – which plants actually perform in the garden?

Tomato plants interplanted with basil and marigolds in a raised bed for pest control

The Best Companion Plants for Tomatoes (Grouped by Benefit)

When I consult for nurseries, I always advise grouping companions by the job they do. Here’s my curated list of best companion plants for tomatoes, backed by both Wageningen research and my own trial beds. I’ve organized them into four categories so you can mix and match according to your needs.

  25 Shade Plants That Thrive in Low Light (2026)

Featured snippet target – top companions at a glance:

  • Basil – repels hornworms and whiteflies, improves flavor and yield.
  • Marigolds (French) – deter root-knot nematodes and aphids.
  • Borage – attracts pollinators, repels tomato hornworms.
  • Nasturtiums – trap crop for aphids; draw pollinators.
  • Garlic – repels red spider mites; antifungal in soil.
  • Parsley – attracts hoverflies that prey on aphids.

Pest-Repelling Herbs & Flowers

Basil is the superstar – I’ve never had a season without it near my tomatoes. The secret? Its VOCs interfere with the olfactory receptors of tomato hornworms. Plant at least one basil per tomato, preferably sweet Genovese or Thai basil. Marigolds deserve a special mention: French marigolds (Tagetes patula) release alpha-terthienyl, a compound that suppresses root-knot nematodes in the soil. A 2022 field trial from Wageningen showed a 35–40% reduction in nematode galling when marigolds were interplanted. African marigolds (T. erecta) are less effective – stick to the French varieties.

Pollinator Magnets for Higher Yields

Tomatoes are self-fertile, but wind and buzz pollination increase fruit set by 20–30%. Enter borage (Borago officinalis) – its blue star-like flowers attract bees and hoverflies. I’ve counted up to 12 bumblebees on a single borage plant. Borage also repels tomato hornworms (some say by masking scent). Another favorite: sweet alyssum (Lobularia maritima), which draws minute parasitic wasps that kill hornworm eggs. Plant a border of alyssum around your tomato bed for continuous pollination through summer.

Nitrogen-Fixers & Living Mulch

Beans and peas fix nitrogen via Rhizobium bacteria. But tall pole beans can shade tomatoes; I prefer bush beans like ‘Provider’ or ‘Contender’ planted in alternating rows. The beans add nitrogen while the tomatoes provide a windbreak. For living mulch, low-growing clover (white dutch or crimson) spreads between rows, suppresses weeds, and fixes nitrogen. However, watch for slugs in damp climates – I learned that the hard way in 2024.

Trap Crops That Sacrifice Themselves

A trap crop is something pests prefer over your tomatoes. Radishes, especially ‘White Icicle’ or ‘Daikon’, lure flea beetles away from tomato leaves. I sow radish seeds two weeks before transplanting tomatoes – the flea beetles attack the radishes, and by the time tomatoes go in, the beetles are already satisfied. Nasturtiums act as a trap for aphids and cabbage loopers. Check them weekly; if you see heavy pest buildup, pull the trap plant and compost it (don’t let pests migrate). This strategy is underutilized but incredibly effective.

Quick checklist: Mark which companions you already grow: Basil Marigolds Borage Nasturtiums Garlic Parsley Bush beans Alyssum

Now that you’ve got a toolbox of companions, let’s look beyond herbs – what about vegetables that live harmoniously with tomatoes?

Planting basil companion near tomato in garden soil for better yield

Vegetables and Fruits That Thrive Next to Tomatoes

Many gardeners ask: “what to plant with tomatoes in a mixed vegetable bed?” The answer extends well beyond basil. Carrots, lettuce, onions, and squash all make excellent neighbors when planted with care. Let’s explore how to integrate them without competition.

Root Vegetables & Tomato Shade

Carrots and radishes thrive in the partial shade cast by tomato plants – especially during hot afternoons. I sow carrot seeds around the base of my tomato cages in early spring. By the time tomatoes are full size, the carrots are already maturing. Timing is everything. Onions and garlic also fit well; they deter pests with their sulfur compounds and occupy a different root zone. I once interplanted red onions between tomatoes in a 4×6 bed and harvested a full crop of 8 kg of onions without reducing tomato yield. That’s nutrient partitioning in action.

Lettuce is another shade-lover. Plant leaf lettuce under the tomatoes’ canopy – it stays cool and stays sweet. Just be careful with head lettuce, which may bolt in the heat. Use a loose-leaf variety like ‘Oakleaf’ or ‘Red Sails’.

  Plant Fertilizer 101: The Ultimate Guide to Choosing and Using Fertilizer for Healthier Plants

Cucurbits as Living Mulch

Cucumbers, squash, and melons spread low, shading the soil and conserving moisture. They are excellent container companion planting tomatoes companions if you have space. However, I recommend placing cucurbits on the north or east side of the bed so they don’t smother tomatoes. A classic polyculture: tomatoes staked in the center, basil at their feet, and cucumber vines trailing at the border. This is exactly what we did in a trial at the Haarlem Community Garden in 2025 – yields were 18% higher than monocropped tomatoes.

Here’s a quick story from a nursery in Friesland: a grower interplanted ‘Marketmore’ cucumbers between tomato rows and used the cucumber leaves as a living mulch. He reported fewer weeds and a 10% increase in tomato brix (sugar content) – possibly because the cooler root zone reduced stress. Don’t overthink it; just remember that low, spreading plants make great companions.

But not every vegetable is a friend. Some will fight your tomatoes for water, nutrients, or even bring in pests. Let’s talk about the five plants I always keep at least 6 feet away from my tomatoes.

5 Plants to Keep Away From Your Tomatoes

Understanding what not to plant near tomatoes is just as important as knowing the good neighbors. I’ve made many mistakes over the years – planting dill too close, for instance – so learn from my trials. Here are the top five antagonists, with the reasons why they don’t belong near your Solanum lycopersicum.

Shared Pests: Corn & Potatoes

Corn and tomatoes share a deadly enemy: the corn earworm (also known as tomato fruitworm). This pest lays eggs on both crops, and when planted together, they create a pest superhighway. Additionally, potatoes are fellow nightshades, susceptible to early blight and late blight. In the wet summer of 2024, I saw a plot where potatoes and tomatoes were interplanted – both crops succumbed to blight within weeks. Keep at least 10 meters between them, or better yet, rotate families.

Allelopathic Inhibitors: Fennel & Rosemary

Fennel is the garden bully. It releases anethole, a compound that stunts the growth of tomatoes, beans, and many others. I’ve seen tomatoes planted just two meters from fennel that remained half the size of those across the garden. Rosemary, on the other hand, isn’t allelopathic but competes aggressively for water and prefers alkaline, dry soil – while tomatoes need consistent moisture. They’re simply incompatible roommates.

Enemy PlantReasonAlternative Companion
CornAttracts same pest (corn earworm)Basil (repels hornworms)
PotatoesShared blight pathogens, nightshadeGarlic (fungal inhibitor)
FennelAllelopathic (anethole)Dill (young, attracts wasps)
RosemaryDifferent water & pH needsThyme (low moisture, living mulch)
Mature dillInhibits tomato growth after floweringYoung dill (beneficial)

Warning: Dill – Friend or Foe? Young dill (before flowering) attracts parasitic wasps that kill hornworms. But once dill bolts and sets seed, it releases compounds that stunt tomato growth. I plant dill on the far end of the bed and remove it after flowering – a simple hack that gives you the best of both worlds.

Now that you know who to avoid, let’s shrink the garden – companion planting is just as powerful in pots and raised beds.

Container & Small-Space Tomato Companion Planting

Not everyone has a sprawling garden. I live in Haarlem with only 80 square meters, but I still grow 10 tomato plants in containers. Container companion planting tomatoes is absolutely feasible if you choose compatible, compact varieties. Let me show you what actually works in pots and troughs.

Choosing Compatible Compact Varieties

Dwarf or determinate tomato varieties like ‘Tiny Tim’ or ‘Bushsteak’ pair well with compact herbs: thyme, oregano, and chives. These herbs have shallow roots and won’t compete for space. For a 5-gallon bucket, plant one tomato in the center and surround it with 2-3 basil plants or a ring of marigolds. My grandmother always tucked a few garlic cloves along the edge of every pot – the scent repels red spider mites, a common container pest.

  15 Hardy Deer Resistant Plants That Survive Hungry Herds

Layering Heights in a Single Pot

Use vertical space: train your tomato up a trellis or stake, and plant trailing nasturtiums at the rim – they’ll spill over and act as a living mulch. Or place a small borage in a separate pot next to the tomato; its deep roots won’t interfere. Quick checklist for container success:

  • Container depth at least 18 inches (45 cm) for root space.
  • Use quality potting mix with added compost.
  • Water consistently – containers dry out faster.
  • Prune suckers to reduce foliage competition.
  • Fertilize every 2 weeks with balanced liquid feed.

In my own balcony trials, I’ve found that a single tomato in a 50-liter container with two basil plants and a marigold produces as much fruit as an in-ground plant – if you water daily and feed weekly. The key is not overcrowding: you want a team, not a mob.

Ready to put it all together? Let’s design a layout that maximizes synergy.

How to Design a Tomato Companion Planting Layout

A well-designed tomato garden layout companion arrangement can double your efficiency. I’ll share two proven plans – one for in-ground beds and one for raised beds – based on what I teach in my workshops at the Haarlem Botanical Garden.

In-Ground Polyculture Plan

In a 4×8 foot (1.2 x 2.4 m) bed: Plant three tomatoes (staked) in a staggered row down the center, spaced 30 inches apart. On each side of the tomatoes, sow a 6-inch strip of basil (distance 8 inches from tomatoes). At the outer edges, plant a border of French marigolds every 12 inches. In the corners, tuck two borage plants. Fill the gaps between basil and marigolds with leaf lettuce or radishes. This layout provides pest repellent (basil, marigolds), pollination (borage), living mulch (lettuce), and a trap crop (radishes). I used exactly this design in 2025 and harvested over 18 kg of tomatoes from a single bed.

Raised Bed Intensive Plan

For a 3×6 raised bed (0.9 x 1.8 m), space four tomatoes (determinate) in a square pattern. Around each tomato, plant three basil seedlings in a ring. Between the basil rings, sow a strip of alyssum for continuous pollination. Use the bed edges for bush beans – they’ll climb a small trellis on the north side. In the spare corners, slip in two nasturtiums for aphid trap. This is a dense polyculture, but with regular feeding, it works beautifully. I adapted this from a system used at a Utrecht community garden.

One more anecdote: a grower in Friesland I know planted 30 heirloom tomato varieties interplanted with onions – he said the onions thrived in the gaps, and the tomatoes yielded 20% more than the previous year. Don’t overthink it: good design is just thoughtful placement.

Frequently Asked Questions About Tomato Companion Planting

Can I plant tomatoes with peppers?

Yes, both are nightshades and share similar growing conditions (full sun, consistent moisture). However, they also share diseases like early blight and verticillium wilt. If you’ve had disease problems in the past, avoid planting them together and rotate crops. In healthy soil, they make fine neighbors.

What flowers repel pests on tomatoes?

French marigolds (Tagetes patula) repel root-knot nematodes and aphids. Nasturtiums act as a trap crop for aphids. Borage attracts pollinators and is said to repel tomato hornworms. Also, sweet alyssum draws beneficial wasps and hoverflies.

Is it okay to plant tomatoes with cucumbers?

Yes, they are excellent companions. Cucumbers spread as ground cover, shielding soil moisture and suppressing weeds. Both prefer similar watering (soaker hoses). Just ensure cucumbers don’t shade the tomatoes – plant them on the edge of the bed.

What should not be planted near tomatoes?

Avoid corn (attracts same pests), fennel (allelopathic), mature dill (inhibits growth), rosemary (different water needs), and potatoes (shared blight). Keep these at least 10 feet away or in separate beds.

Can I plant basil next to tomatoes in a pot?

Absolutely. Basil thrives in the same conditions and its scent repels whiteflies and hornworms. Plant one basil per tomato in an 18-inch diameter pot. Space herbs like thyme or oregano also work well in containers.

How many companion plants do I need per tomato?

A general guideline: 1–2 basil plants per tomato, a ring of marigolds every 2–3 feet, and a few borage or nasturtiums around the bed. Don’t overcrowd – each companion should have room to grow without blocking air circulation.

Does companion planting actually increase tomato yield?

Yes, multiple mechanisms contribute. A 2023 meta-analysis from Wageningen University found average yield increases of 15–25% with strategic companion planting, primarily due to improved pollination and reduced pest pressure. In my own trials, a polyculture bed consistently outyields a monoculture by at least 20%.

Now that you have all the science, strategies, and practical layouts, it’s time to get your hands dirty. Pick three companions from the list and add them to your tomato patch this season. The plant will tell you if it’s happy – watch for strong growth, fewer pests, and plenty of fruit. Happy growing!

Frond & Soil
Privacy Overview

This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.