Grow these plants with tomatoes to save space and improve your harvest

Tomatoes grow well with basil, carrots, onions, parsley, and marigolds in the same raised bed. These companions either use different soil depths, repel pests that target tomatoes, or improve flavor. The key is spacing: tomatoes need room for air to move around their leaves, so plant companions at the edges or underneath rather than crowding the center. A 4-by-8-foot bed typically holds one or two tomato plants plus 3 to 5 companion plants, depending on variety size.

Pairing plants this way cuts down on the number of beds you need and uses the vertical space tomatoes create. Basil and parsley grow in the shade cast by tomato foliage in midsummer, while shallow-rooted plants like onions and carrots pull nutrients from different soil layers than tomatoes do. Some companions, like marigolds, attract beneficial insects or confuse pests. Others, like basil, straightforward taste better when grown near tomatoes.

Key Takeaways

  • Basil, carrots, onions, parsley, and marigolds all grow successfully in the same raised bed as tomatoes without competing for the same resources.
  • Plant companions around the edges of the bed or underneath tomato foliage, not in the center where tomato roots spread and air circulation matters most.
  • Shallow-rooted plants like onions and carrots draw water and nutrients from the top 6 to 8 inches of soil, while tomato roots go deeper, so they do not fight for the same supply.
  • Marigolds and nasturtiums repel or distract common tomato pests like hornworms and whiteflies, reducing the need for sprays.
  • Avoid planting brassicas (cabbage, broccoli, kale) or fennel in the same bed, as they compete with tomatoes or inhibit their growth.

Basil: the flavor-boosting companion

Basil is the most popular tomato companion because it grows quickly, tastes excellent with tomato dishes, and repels spider mites and thrips. Plant basil seedlings or seeds around the base of tomato plants once soil warms to at least 60°F. Space basil 6 to 8 inches from the tomato stem. In a 4-by-8-foot bed with one large tomato plant, you can fit two or three basil plants in the corners or along the edges.

Basil reaches 12 to 18 inches tall and prefers the same watering schedule as tomatoes—consistently moist but not waterlogged. Pinch off basil flower buds as they appear to keep the plant bushy and productive. You can harvest leaves once the plant has at least six true leaves, usually 4 to 6 weeks after planting. Basil dies at the first frost, so plan to harvest heavily in late summer or dry leaves for storage.

Carrots and onions: root crops that share space efficiently

Carrots and onions occupy the top 6 to 8 inches of soil, while tomato roots extend 12 to 24 inches deep. This vertical separation means they do not compete for water or nutrients. Plant carrot seeds directly into the bed in early spring, 2 to 3 weeks before tomatoes go in. Space carrots 2 inches apart in rows, and thin seedlings to 3 to 4 inches once they sprout. Onion sets (small bulbs) go in 4 to 6 inches apart.

Both crops tolerate partial shade from tomato foliage in midsummer, which actually helps carrots stay tender in hot climates. Carrots take 60 to 80 days to mature, depending on variety, so plant them early enough to harvest before frost. Onions need 100 to 120 days and benefit from consistent moisture. Plant carrots and onions around the perimeter of the bed or in a narrow row along one edge, leaving the center clear for tomato growth and air flow.

Parsley and other herbs that thrive in tomato shade

Parsley, chives, and oregano all grow well alongside tomatoes and tolerate the dappled shade that develops as tomato plants mature. Parsley is a biennial that produces leaves for two seasons; plant it in early spring so it establishes before summer heat. Space parsley plants 6 to 8 inches apart. Chives spread slowly and can stay in the same spot for years, making them a low-maintenance edge plant. Oregano is perennial in most climates and will return year after year if you mulch it in winter.

These herbs need less water than tomatoes once established, so plant them slightly away from the drip line of the tomato plant. Harvest parsley and chives regularly to encourage bushier growth. Oregano and other Mediterranean herbs prefer drier soil, so if your tomatoes are in a consistently wet area of the bed, place herbs on the higher or better-draining side. All three pair well with tomatoes in the kitchen as well as the garden.

Marigolds and nasturtiums: pest-repelling flowers

Marigolds and nasturtiums attract beneficial insects and confuse or repel pests that target tomatoes. Marigolds emit a scent that deters spider mites, whiteflies, and some nematodes in the soil. Nasturtiums attract aphids, drawing them away from tomatoes—they act as a sacrificial crop. Plant marigolds around the perimeter of the bed, spacing them 8 to 12 inches apart. Nasturtiums can sprawl, so plant them at the edges where they have room to spread without shading tomatoes.

Both flowers bloom all season if you deadhead spent blooms (pinch them off as they fade). Marigolds tolerate heat and drought better than nasturtiums, which prefer cooler weather and consistent moisture. In hot climates, nasturtiums may stop blooming in peak summer but resume in fall. Neither flower competes significantly with tomatoes for nutrients, and both are edible if you want to add them to salads. Plant them in early spring from seed or transplants.

Plants to avoid planting with tomatoes

Brassicas—cabbage, broccoli, kale, and cauliflower—compete with tomatoes for the same nutrients and should not share a raised bed. Fennel inhibits tomato growth through a chemical it releases into the soil, so keep it in a separate bed or container. Potatoes and peppers are susceptible to the same diseases as tomatoes, so planting them together increases the risk that a disease will spread from one plant to the other. Corn and tomatoes both need full sun and compete for space, making them poor companions in a small raised bed.

Avoid planting tomatoes near walnut trees (not usually an issue in raised beds, but worth noting) because walnut roots release juglone, a chemical toxic to tomatoes. If you are rotating crops, do not plant tomatoes where potatoes, peppers, or eggplants grew the previous year, as they share soil-borne diseases. Plan your bed layout before planting to may support you are not accidentally placing incompatible plants side by side.

Spacing and layout for a typical raised bed

A 4-by-8-foot raised bed can hold one large indeterminate tomato variety (one that grows tall and produces all season) or two determinate varieties (compact, bush-type tomatoes that produce a heavy crop at once). If you choose one large plant, arrange companions in a circle around it: basil at 6 to 8 inches, marigolds at 12 inches, and a row of carrots or onions along one edge. If you plant two determinate tomatoes, space them 24 to 30 inches apart and place companions between and around them.

Leave at least 12 inches of clear space around each tomato stem for air circulation and to prevent disease. Tomato foliage should not touch the soil or other plants' leaves, as this traps moisture and encourages fungal problems. Arrange taller companions (basil, parsley) on the north side of the bed so they do not shade shorter plants like carrots. Water at the soil level, not overhead, to keep leaves dry. Mulch around all plants with 2 to 3 inches of straw or wood chips to retain moisture and suppress weeds.

Frequently Asked Questions

Can I plant lettuce or spinach with tomatoes?

Yes, lettuce and spinach grow well in tomato shade during spring and fall. Plant them early in the season before tomato foliage gets dense, or wait until midsummer when heat slows tomato growth and shade becomes welcome. Both prefer cooler weather, so they often bolt (go to seed) in peak summer. Space them 4 to 6 inches apart along the bed edges.

How close can I plant basil to a tomato stem?

Plant basil at least 6 to 8 inches away from the tomato stem. Tomato roots spread outward as the plant grows, and basil needs its own root space. Closer spacing can stunt basil or create competition for water during dry spells. If space is very tight, grow basil in a separate container next to the bed.

Do companion plants actually reduce pests, or is that a myth?

Companion planting reduces some pests but is not a complete solution. Marigolds and nasturtiums do attract beneficial insects and confuse some pests, but they will not eliminate hornworms or late blight. Use companion planting as one tool alongside proper spacing, air circulation, and monitoring for problems. Remove diseased leaves promptly and water at soil level to prevent fungal issues.

What if my raised bed is smaller than 4 by 8 feet?

In a 2-by-4-foot bed, plant one determinate (bush) tomato and one companion, such as basil or a row of carrots. In a 3-by-6-foot bed, one large tomato plus two or three companions works well. Prioritize basil and marigolds if space is limited, as they offer the most benefit relative to their size. Avoid overcrowding, which reduces air flow and increases disease risk.

Can I plant tomatoes with beans or peas?

Bush beans and peas can grow alongside tomatoes, though they need full sun like tomatoes do. Plant them on the edges where they receive at least 6 hours of direct sun. Beans and peas fix nitrogen in the soil, which benefits tomatoes, but they do not shade well and may compete for space in a small bed. They are better suited to a separate area or a larger bed with room for all plants to spread.