What Is Companion Planting and Why Does It Work?

Companion planting is the practice of growing different plants in close proximity so they benefit one another. The benefits vary: some pairings deter pests through scent or visual disruption, others fix atmospheric nitrogen into the soil, and still others provide physical shade or structural support that neighboring plants need.

The science behind companion planting is a mix of well-documented biology and long-standing agricultural tradition. Nitrogen fixation by legumes — beans and peas — is well established: root bacteria called rhizobia convert atmospheric nitrogen into a form plants can use, effectively fertilizing neighbors. Pest deterrence through aromatic compounds is widely observed in practice, though results can vary by garden environment and region.

If you're deciding how to lay out your planting space, whether in a raised bed or in-ground plot, understanding companion relationships can help you plan more efficiently. See our comparison of raised beds and in-ground planting for layout considerations that work well with companion systems.

Companion Planting Has Limits

Companion planting works best as one layer of an integrated garden strategy, not as a standalone pest or fertility solution. Results can vary significantly based on your climate, soil health, local pest pressure, and planting density. Treat reported benefits as guides informed by experience and some research — not guaranteed outcomes. Healthy soil and good cultural practices remain the foundation.

Classic Pairings That Work

Certain companion combinations have earned a reliable reputation across generations of home gardeners:

1

Plant basil alongside tomatoes to deter aphids and thrips.

Basil's volatile oils are thought to repel several common tomato pests, and many gardeners report healthier foliage when the two are grown together. The pairing also makes harvest easy — both mature at the same time and are used together in the kitchen.

Example: Tuck two or three basil plants at the base of each tomato cage to create a fragrant border that also discourages hornworms.
2

Use the Three Sisters combination — corn, beans, and squash — in one bed.

This Native American planting system is one of the most complete companion arrangements documented. Corn provides a trellis for climbing beans; beans fix nitrogen that feeds the corn and squash; squash leaves shade the soil, retaining moisture and blocking weeds.

Example: Plant corn in a block first, add pole beans around the base once corn is 6 inches tall, then sow squash seeds in the surrounding open spaces.
3

Grow marigolds around the perimeter of vegetable beds to deter nematodes and beetles.

French marigolds (Tagetes patula) are well-documented as a suppressor of root-knot nematodes in the soil, particularly when grown densely for a full season. Their scent also confuses whiteflies and other flying pests.

Example: Border a raised tomato and pepper bed with a single row of French marigolds planted at the same time as your transplants.
4

Interplant dill or fennel (in isolation) near brassicas to attract beneficial predatory insects.

Umbellifers like dill produce small, nectar-rich flowers that draw parasitic wasps and hoverflies — both of which prey on cabbage worms and aphids. This reduces the need for manual pest removal on broccoli, cabbage, and kale.

Example: Place a small dill patch adjacent to (not mixed into) your brassica row so beneficial insects patrol the area without competition.
5

Pair carrots and onions to mutually deter their primary pests.

Carrot fly and onion fly are both confused by the alternate scents when the two crops are grown in alternating rows. This simple interplanting technique has a long track record in kitchen gardens across the US and UK.

Example: Sow alternating short rows of carrots and onions in the same bed, spacing them at their normal recommended distances.

Once your garden is producing well, you might also consider how you prepare your harvest. Our guide on preparation methods that change vegetable texture and taste offers ideas for making homegrown produce more appealing to the whole family.

Plants That Should Stay Apart

Just as some plants thrive together, others compete or actively suppress their neighbors. Keeping these pairs separated protects your harvest:

  • Fennel and almost everything: Fennel releases allelopathic compounds — natural chemicals that inhibit the growth of nearby plants. Keep it isolated in its own container or a distant corner of the yard.
  • Onions and beans or peas: Alliums (onions, garlic, leeks) suppress the growth of legumes. Plant them in different beds entirely.
  • Tomatoes and brassicas: Broccoli, cabbage, and kale compete with tomatoes for soil nutrients and can stunt each other's development when crowded together.
  • Dill and tomatoes: Mature dill can inhibit tomato growth, though young dill planted briefly nearby may attract beneficial insects before it flowers.

Keeping a simple garden journal helps you track which pairings succeeded or caused problems in your specific conditions — soil type, sun exposure, and climate all influence outcomes.

high Tuck a basil seedling next to each tomato transplant when you set out your tomatoes this season.
high Plant a ring of French marigolds around any bed where you've had aphid or whitefly problems in past seasons.
medium Move fennel to a container away from your main beds to prevent it from suppressing neighboring vegetables.
medium Sketch a simple companion-planting map of your beds before you plant this spring, noting compatible and incompatible neighbors.

Building Your Companion Planting Plan

Effective companion planting starts at the planning stage, not after your seeds are in the ground. Sketch your beds on paper before planting, grouping compatible plants and noting which need full sun, which tolerate shade, and how large they'll grow at maturity.

If you're starting from seed, timing relationships matter too — some companion plants need a head start to be in place when their partners go in. Our article on seeds versus transplants can help you decide which starting method suits each plant in your pairing strategy.

Healthy soil underpins every companion system. Compost provides the nutrient baseline that allows companion pairings to reach their potential. If you haven't started a compost routine yet, our guide on composting kitchen scraps at home is a straightforward starting point.

Finally, rotate your companion groups each season — move the legume bed to where you previously grew heavy-feeding crops like tomatoes or corn. This prevents soil depletion and reduces disease carryover. Even small gardens benefit from a simple two- or three-zone rotation.

10–25%

Potential yield increase from legume nitrogen fixation

Research published in agricultural extension literature suggests legumes can supply meaningful nitrogen to companion crops, though results depend on soil conditions and inoculant use.

Over 50%

Nematode reduction from French marigold cover crops

University extension studies have shown that a full season of densely planted French marigolds can meaningfully suppress root-knot nematode populations in vegetable garden soil.

Share

Home & Garden Editorial Team · Contributor

Home & Garden Editorial Team is the collective byline for our editorial team and contributor network. Articles published under this byline or an editorial pen name are researched, written, and reviewed according to our editorial standards for clarity, consistency, and independence before publication.

The content provided on our blog site traverses numerous categories, offering readers valuable and practical information. Readers can use the editorial team’s research and data to gain more insights into their topics of interest. However, they are requested not to treat the articles as conclusive. The website team cannot be held responsible for differences in data or inaccuracies found across other platforms. Please also note that the site might also miss out on various schemes and offers available that the readers may find more beneficial than the ones we cover.