
Walk through any thriving vegetable patch, and you’ll notice something: the best gardens look less like neat rows and more like good neighborhoods. Certain plants seem to lean toward each other, while others sit as far apart as possible. That’s not an accident. It’s companion planting, and once you understand the basics, you’ll start seeing your garden bed as a community instead of just a collection of individual plants.
Companion planting simply means placing plants together so they help each other out. Some pairs share nutrients well, some confuse pests, and some just make better use of the same patch of dirt. Other combinations compete for the same resources or release chemicals that slow each other down. No matter where you garden, from a balcony container in a city apartment to a half-acre plot in the country, a little matchmaking can make a real difference.
The Classic: Tomatoes and Basil
This pairing earns its reputation. Basil is often credited with repelling certain insects that bother tomatoes, including thrips and some types of flies, though the research on this is mixed. What’s not up for debate is the practical benefit: basil stays low and shaded under tomato foliage, so you’re using vertical space efficiently in a small bed. And when it’s time to cook, you’ve got the makings of a Caprese salad growing six inches apart. Plant your basil around the base of the tomato cage once the seedlings have a few true leaves, and water at the soil level so the basil doesn’t get scorched by midday sun bouncing off wet leaves.
Beans, Corn, and Squash
Indigenous farmers across North America developed this ‘three sisters’ combination long before anyone used the term “companion planting.” Corn grows tall and gives beans something to climb. Beans pull nitrogen from the air and deposit it in the soil through their roots, feeding the heavy-feeding corn and squash nearby. Squash spreads its broad leaves across the ground, shading out weeds and keeping soil moist. Each plant does a job that the others can’t do for themselves. If you want to try this in your own bed, give it room. This isn’t a combo for a tight raised bed; it needs space to sprawl.
Marigolds with Veggies
Marigolds get planted everywhere for a reason. Their roots release compounds that may discourage certain nematodes (microscopic worms that damage plant roots) in the soil, and their strong scent can throw off some pests looking for your tomatoes, peppers, or squash by smell. Tuck them along the border of any vegetable bed, and they’ll do their quiet work all season while also giving you cut flowers for the kitchen table.
Nasturtiums as a Decoy
If you’ve ever lost a squash plant to aphids, nasturtiums might become your new best friend. They’re what gardeners call a “trap crop,” meaning aphids often prefer them over your vegetables and will collect there instead. Plant a few near your squash, cucumbers, or beans, and check the nasturtiums regularly. When you see aphids gathering, you can deal with them in one spot rather than chasing them across your whole bed.
Now for the Breakups
Just as some plants thrive together, others need to be kept apart.
Beans and onions don’t get along well. Onions (and their relatives, garlic and leeks) release compounds into the soil that can slow down bean growth. If you’re planning your bed layout, keep these two on opposite sides.
Potatoes and tomatoes both belong to the nightshade family, which means they’re vulnerable to the same diseases and pests, including blight. Planting them near each other increases the odds that a problem affecting one will jump to the other. Give them separate beds if you can, and definitely don’t follow one with the other in the same spot next season.
Fennel is the loner of the vegetable garden. It releases compounds that can stunt the growth of many neighboring plants, including tomatoes, beans, and most other vegetables. If you love growing fennel, give it its own dedicated corner of the yard.
Bringing It into Your Own Backyard
You don’t need to redesign your entire garden to put this into practice. Start small. If you’re already growing tomatoes, add a few basil plants at the base this season. If squash has struggled with pests before, plant nasturtiums alongside it next time. Pay attention to what happens, because every yard has its own particular mix of sun, soil, and bug pressure, and the plant pairings that work beautifully for one gardener might need adjusting for another. Climate varies enormously across the country, so a pairing that thrives in a long, humid growing season may behave differently somewhere with a shorter season or drier air. Local extension offices and experienced gardeners in your specific region are always worth a conversation when you’re trying something new.
That’s really the heart of companion planting: paying closer attention to how your plants interact, then making small adjustments based on what you observe. Once you start gardening this way, you stop thinking about your vegetable bed as separate plants in separate holes. You start seeing it as a small, living system where every choice affects something else.
