25 Best Companion Plants for Rosemary
Pair rosemary with lavender, brassicas, alliums, and pollinator flowers that share its dry, sunny culture—and learn which moisture-loving crops to keep at a distance.

Rosemary (Salvia rosmarinus) is one of the most useful herbs in a kitchen garden—aromatic, evergreen in mild climates, and genuinely tough once established. It also shows up on nearly every companion-planting chart. The problem is that most charts treat rosemary like a universal pest shield you can tuck beside anything that needs “protection.” In real beds, rosemary succeeds or fails with neighbors for a simpler reason: it wants full sun, sharp drainage, and soil that dries between soakings. Pair it with moisture-loving crops on the same watering schedule and you will rot roots long before any scent masking helps.
This guide lists 25 companions worth planting, groups them by the job they do, and explains what to keep at a distance—with spacing, container tricks, and water-zone rules you can apply this season.
What companion planting can—and cannot—do for rosemary
Companion planting means growing two or more crops close enough that at least one benefits—through pest confusion, pollinator support, efficient use of space, or compatible root zones. Penn State Extension’s work on herbs as plant partners notes that fragrant herbs can mask crop volatiles and sometimes reduce pest egg-laying, but they confuse pests more than they permanently repel them. The RHS companion planting overview is equally clear: benefits exist in some combinations, not for every crop in every garden.
For rosemary specifically, neighbors earn their spot when they do at least one of these jobs:
- Share dry, sunny culture so you are not drowning one plant to keep another alive
- Bloom early to feed bees before vegetable flowers open
- Occupy a different root depth so harvest does not mean root fights
- Add scent complexity that may make brassicas and root crops harder for some insects to find
- Edge the bed as a woody perennial while annuals cycle through the center
No rosemary border replaces rotation, scouting, or row cover on caterpillar-prone crops. Treat companions as one layer in a diverse polyculture—not a substitute for integrated pest management. For the broader science, see our guide on whether companion planting actually works.
How rosemary actually uses neighboring plants
Rosemary is a woody Mediterranean shrub with a deep, spreading root system once mature. The RHS rosemary grow-your-own guide describes it as drought tolerant in the ground, intolerant of waterlogged winter soil, and happiest in poor to moderately fertile, well-drained ground. It does not need rich nitrogen the way cucumbers or corn do; in fact, overly fertile, wet soil produces lush, floppy growth with weaker flavor and more disease risk.
That culture profile means rosemary’s best companions are usually other dry-garden plants, alliums with shallow roots, brassicas kept on a moisture split, or flowers planted at the sunny edge where drainage stays sharp. The worst failures happen when gardeners plant rosemary in the middle of a daily-watered summer row—tomatoes, basil, cucumbers, pumpkins—and wonder why the herb turns brown at the base by August.

Set up the rosemary bed before you pick companions
Before you memorize a list of 25 names, sort your bed into moisture zones. This single step prevents more rosemary deaths than any pest-repellent claim.
Moisture zones, spacing, and container vs in-ground rules
Dry Mediterranean zone (rosemary’s home): Full sun, soil that drains in hours after rain, watering only when the top 2 inches are dry in summer. Group lavender, sage, thyme, oregano, marjoram, and rosemary here. In heavy clay, use a raised mound or raised bed with grit or coarse sand mixed into the top 8 inches.
Moderate zone: Crops that want even moisture but still need drainage—carrots, parsnips, onions, garlic, chives, peppers, strawberries, beans. Rosemary can live at the dry edge of this zone if the center of the row gets more water. Think end-of-row placement or a slight slope so water drains away from the herb.
Moist warm-season zone: Basil, tomatoes, cucumbers, pumpkins, melons. Keep rosemary at least 3–4 feet away or in its own pot with a separate drip line. Our herb companion plants guide walks through why basil and rosemary fail in the same root zone even though both like sun.
Spacing: Allow 18–24 inches between young rosemary plants and 24–36 inches once woody shrubs mature. Perennial herbs at the corner of a vegetable bed should not be stepped on or disturbed at harvest. If you are building a dedicated herb strip, 12–15 inches between low herbs (thyme, oregano) and 24 inches back from rosemary is a workable minimum.
Containers: A 30 cm (12 in) or larger pot with drainage holes is often the most flexible companion strategy. Place the pot at the dry end of a brassica row, beside a patio pepper, or at the base of a young fruit tree—close enough to help with scent, far enough that daily tomato watering does not soak rosemary roots. Terra cotta dries faster than plastic; that is an advantage here, not a drawback.

Mediterranean herb companions that share rosemary’s culture
The strongest rosemary pairings are other sun-loving, drought-adapted herbs that will not ask for a different watering script. These five are the backbone of a dry herb border.
Lavender, sage, thyme, oregano, and marjoram
Lavender (Lavandula spp.) and rosemary are the classic Mediterranean pairing: both want full sun, alkaline-leaning, well-drained soil, and minimal fertility. Plant lavender slightly forward of taller rosemary so air circulates between woody stems. In cold-winter regions, lavender may survive lower temperatures than tender rosemary cultivars—check your USDA zone and consider a sheltered wall for both.
Sage (Salvia officinalis) matches rosemary’s culture almost exactly. Both are woody perennials that resent wet crowns in winter. Give each 24 inches of space so mature plants do not compete for the same soil volume. Sage and rosemary together make a useful scented border along a path where brushing the foliage releases oils that may confuse some pests. See also our bad sage companion plants guide for moisture mismatches on the other side of the bed.
Thyme (Thymus vulgaris) stays low—often 6–8 inches—and can carpet the soil in front of rosemary without blocking sun. Thyme is widely used near brassicas because its oils may deter some caterpillars; combined with rosemary’s stronger scent, the pair is a reasonable edge planting in front of cabbage or kale rows. Harvest thyme lightly so some stems can flower for pollinators.
Oregano (Origanum vulgare) spreads by runners in fertile soil. In a dry herb bed, that spreading habit becomes living mulch that shades soil without raising humidity at rosemary’s crown. Keep oregano 6–12 inches from rosemary’s main stem so the shrub’s base stays open to air.
Marjoram (Origanum majorana) is often listed as a “growth booster” in companion charts. Some gardeners report better flavor in nearby vegetables; the mechanism is anecdotal more than proven in field trials. What is solid: marjoram shares rosemary’s sun and drainage needs and stays compact enough for a mixed herb planter or rock-garden edge.
Together, these five herbs are companions 1–5 on the full list: lavender, sage, thyme, oregano, and marjoram.

Pollinator flowers and living mulch for a rosemary border
Flowers earn space beside rosemary when they feed beneficial insects without demanding daily soaking. These four are reliable in dry, sunny edges.
Alyssum, marigolds, zinnias, and borage
Sweet alyssum (Lobularia maritima) is a low, honey-scented annual that blooms for months in cool-to-warm weather. The RHS notes research showing alyssum with lettuce can reduce aphids by attracting predators that feed on nectar and pollen. Tuck alyssum along the front lip of a rosemary bed—6 inches from the shrub—so it spills over the edge without crowding woody stems.
Marigolds (Tagetes spp.), especially French types, are traditional vegetable-garden companions. Research cited by the RHS links marigold volatiles such as limonene to reduced whitefly and thrips pressure on some crops. A ring of marigolds around—not under—rosemary gives color and may help at the bed perimeter. For tomato-focused pairings, see our marigold companion plants guide.
Zinnias (Zinnia spp.) want full sun and tolerate dry spells once established, making them a better flower match for rosemary than moisture-hungry annuals. They attract butterflies and bees to the garden at large, which helps peppers, strawberries, and fruit trees nearby. Our companion plants for zinnias page covers spacing when zinnias are the anchor plant instead of rosemary.
Borage (Borago officinalis) is a tall, self-seeding annual with star-shaped blue flowers that bees love. It prefers well-drained soil and tolerates dry periods better than cucumbers or squash. Plant borage at the back of a mixed bed where its 2–3 foot height will not shade low thyme or alyssum. It can reseed heavily—pull extras if you do not want it every year.
These four flowers are companions 6–9: alyssum, marigolds, zinnias, and borage.

Brassicas that benefit from rosemary’s scent masking
Cabbage-family crops attract cabbage moths, loopers, and flea beetles that find plants partly by scent. Rosemary’s volatile oils may mask brassica volatiles in some gardens—observational, not guaranteed, but a low-cost experiment at the row end.
Cabbage, broccoli, cauliflower, and Brussels sprouts
Cabbage (Brassica oleracea var. capitata) wants steady moisture and fertile soil. Rosemary wants the opposite at the root zone. The workable compromise: rosemary in a pot or dry mound at the row end, brassicas in the irrigated center. Space cabbage 12–18 inches apart and keep rosemary 2–3 feet from the wettest part of the row.
Broccoli benefits from the same layout. Iowa State and Penn State companion-planting material often pairs thyme and rosemary with brassicas for pest confusion; our broccoli companion plants guide groups herbs by pest job if broccoli is your main crop.
Cauliflower is even less drought tolerant than cabbage. If you only have one rosemary plant, place it upwind and uphill from cauliflower so irrigation water drains away from the herb.
Brussels sprouts share brassica pests and culture with cabbage. A rosemary shrub at the corner of a Brussels sprout block is a common kitchen-garden layout in mild climates where rosemary stays evergreen.
These four brassicas are companions 10–13: cabbage, broccoli, cauliflower, and Brussels sprouts.

Root crops and alliums for layered planting
Root vegetables and alliums occupy different soil layers than rosemary’s deeper roots—classic “good neighbors” spacing from extension polyculture advice.
Carrots, parsnips, onions, garlic, and chives
Carrots (Daucus carota) are shallow to mid-root crops that appreciate loose soil. Sow carrots between young rosemary transplants only if rosemary is on a dry mound and carrots receive water short of soaking the mound. Many growers plant carrots along the moderate-moisture side of the bed with rosemary on the dry lip—companions 14 on the list.
Parsnips follow the same rule as carrots: same row only with a water split. Parsnip flies may be confused by strong aromatics in some gardens; rotation and fine mesh row cover still matter more than scent alone.
Onions and garlic (Allium spp.) are among the safest rosemary neighbors. Shallow allium roots rarely compete with rosemary, and sulfur compounds from alliums add another scent layer in the bed. Plant onion sets 4–6 inches from a young rosemary plant, farther from mature shrubs. Garlic cloves spaced 6 inches apart in an autumn row with rosemary at the dry end is a low-maintenance spring harvest pairing—companions 15–17.
Chives (Allium schoenoprasum) are compact, perennial, and tolerate dry edges once established. They may help with aphid pressure on nearby crops when allowed to flower. Chives are companion 18.

Beans, peppers, and strawberries in the same polyculture
These three popular crops appear on many rosemary lists—but each needs a nuanced placement, not a blanket “plant together” label.
Beans (Phaseolus spp.) fix nitrogen in soil. Rosemary thrives in lean soil; excess nitrogen can produce soft, leggy growth with less concentrated flavor. Beans still work as companions 19 when rosemary sits in its own container beside a bean trellis, receiving only incidental nitrogen—not a heavy sidedress aimed at the herb. Bush beans need 6 inches between plants; keep the rosemary pot outside the bean root zone.
Peppers (Capsicum spp.) want sun and warm soil but more even moisture than rosemary. Plant rosemary at the base of a pepper cage on the outside where drip irrigation hits peppers first. Aphids and spider mites on peppers are best managed with water sprays, beneficial insects, and early removal—rosemary scent is a minor bonus.
Strawberries (Fragaria × ananassa) spread by runners and like consistent moisture. Pair them with rosemary only on separate drip zones: strawberries in the irrigated strip, rosemary in a pot or dry corner. Strawberries as living ground cover can suppress weeds near—but not on top of—rosemary’s crown. Strawberries are companion 20.

Fruit trees and berries near rosemary—what actually works
Woody perennials and fruiting shrubs bring a different scale to companion planning. Rosemary’s shrub form is an asset here if you respect soil chemistry and water.
Apple and cherry trees; raspberries; why blueberries are a poor fit
Apple trees (Malus domestica) and cherry trees (Prunus spp.) are companions 21–22 when rosemary is planted as a low shrub ring near the trunk—not against the graft union. Young trees need regular water; established rosemary near the drip line on the sunny side gets enough moisture from rainfall in many climates without daily soaking at the trunk. Strong aromatics may discourage some rodents and browsing insects in anecdotal reports; hardware cloth around young trunks still beats any herb for rabbit protection.
Raspberries (Rubus idaeus) want well-drained but moist soil and full sun. A rosemary plant at the end of a raspberry row on slightly higher ground can work; mixing them in the same constantly wet furrow will rot one or the other.
Blueberries (Vaccinium spp.) are often listed beside rosemary online—and that is bad advice. Blueberries need acidic soil (pH 4.5–5.5) and steady moisture. Rosemary prefers neutral to alkaline, sharply drained conditions. You cannot acidify a zone for blueberries while keeping rosemary happy in the same patch. If you grow both, put blueberries in a separate acid bed and rosemary in the dry herb strip. Treat blueberries as a what not to plant neighbor, not companion 23.
For acid-loving fruit culture, see our acid-loving plants guide.
Plants you should not plant near rosemary
Companion success with rosemary is mostly cultural compatibility. These crops fail for predictable water, fertility, or space reasons.
Basil, mint, tomatoes, cucumbers, and pumpkins
Basil wants consistently moist soil and rewards daily attention in summer heat. Rosemary rots when kept that wet. Keep them in the same garden if you like, but separate by bed or container—never the same 12-inch pot.

Mint (Mentha spp.) is a worse neighbor: aggressive rhizomes, high moisture, and shade tolerance let it overrun rosemary within a season. Grow mint in a buried pot or separate bed 10 feet from woody herbs.
Tomatoes need deep, regular watering and heavy feeding. Rosemary at the tomato root zone is a common mistake. If you want both, use our tips for protecting tomatoes from pests for real controls and plant rosemary across the path in dry soil.
Cucumbers and pumpkins are companions you should reject for rosemary beds. They demand high nitrogen and constant moisture, share powdery mildew pressure in humid summers, and sprawl over low herbs. Cucumber culture is covered in our companion plants for cucumbers guide—keep rosemary out of that wet row entirely.
Fennel deserves an honorable mention in the “avoid” column: allelopathic compounds can inhibit nearby herbs and vegetables. Plant fennel at the orchard edge, not in the rosemary patch.
Three rosemary companion layouts that work in small gardens
Layout 1 — Dry herb border: Lavender, rosemary, sage, thyme, and oregano on a south-facing strip with gravel mulch. Alyssum and marigolds at the front. No vegetables in the root zone—just herbs and flowers.
Layout 2 — Brassica row end: Irrigated cabbage or broccoli down the center; rosemary in a terra cotta pot at each end; chives and carrots on the moderate-moisture side; marigolds every 4 feet along the outer edge.
Layout 3 — Fruit and kitchen polyculture: Young apple tree with rosemary and garlic chives in the sunny drip line; strawberries on their own drip zone away from the herb; beans on a trellis behind the tree with rosemary in a pot so nitrogen does not push the herb into sappy growth.
Adjust planting dates with our when to plant vegetables calendar so cool brassicas go in before summer heat and rosemary transplants after soil warms in spring.

Conclusion
Rosemary is a excellent edge plant, container herb, and dry-garden anchor—not a universal pest shield. The 25 best companions in this guide are lavender, sage, thyme, oregano, marjoram, alyssum, marigolds, zinnias, borage, cabbage, broccoli, cauliflower, Brussels sprouts, carrots, parsnips, onions, garlic, chives, beans (with separation), peppers (with a water split), strawberries (on their own drip zone), apple trees, cherry trees, and raspberries. Blueberries belong on the avoid list despite what many listicles claim.
Match neighbors by water and drainage first, use rosemary in pots when the vegetable row must stay wet, and treat scent masking as a bonus on top of rotation and scouting. Get those three rules right and rosemary will repay you with years of harvests—and neighbors that actually thrive beside it.



