The top 5 plants that repel ants, according to gardening pros

Wave goodbye to creepy crawlies by planting these flowers and herbs

Three pictures of plants that repel ants - a cluster of purple lavender, a close-up of a green basil plant, and a rosemary plant with purple flowers
(Image credit: Getty Images / Olivia Bell Photography / Sergio Amiti / Jasenka Arbanas)

If you've got lots of ants in your backyard, you don't have to resort to nasty chemicals in order to remove them. Instead, try planting greenery that will ward them off instead.

I've asked gardening pros for the ones they recommend adding to your yard, and they're all easy to bring in and maintain. From flowers like luscious lavender to herbs like beautiful basil, there are plenty of options to try.

If you're trying to get rid of ants in your backyard, I recommend getting your gardening gloves on and going for natural solutions such as these.

1. Basil

A birds eye shot of a dark green basil plant, with other leafy plants below it

(Image credit: Getty Images / Sergio Amiti)

This herb is a great choice for your backyard, as it will also provide a delicious fragrance as well as repelling ants.

“Basil strongly smells of oils like eugenol, which is a real turn-off for ants and other pests,” explains Matthew Wilson, gardener at Handy Gardeners.

He recommends planting this in rich, well-drained soil with full sun, as well as pinching off flowers to promote leaf growth and retain the repellency of the plant.

2. Mint

A birds eye shot of bright green mint leaf plants outdoors

(Image credit: Getty Images / mtreasure)

Mint is such a brilliant all-rounder, with it not only tasting wonderful in cool drinks but also repelling ants effectively.

“Ants avoid mint due to the barrier of the menthol oils found in the mint herb,” Matthew says. “The fast growth and the spreading form of this herb makes it a relatively good ground cover.”

If you don’t want it to do this, Matthew suggests growing it in containers to keep its growth under check. 

“I also advise regularly harvesting the leaves for use in cooking, which will help the plant stay in good health and in a potent stage of its life cycle,” he adds.

3. Lavender

A cluster of purple lavender plants with light green stems, with a light blue sky above

(Image credit: Getty Images / Olivia Bell Photography)

I have a lavender plant in my backyard where I’m also growing vegetables, so I’m thrilled that not only does it smell good, but it is also working to deter ants from my outdoor space.

Matthew explains, “Lavender, with its key ingredients or oils, such as linalool, produces a fragrance that repels ants while making your yard look good.

“Planting lavender around entry points like patios, decks, and foundations creates a barrier against ants,” adds Sal Musto, gardener and landscaping expert at SalCorp Landscaping & Construction.

Just make sure to prune it regularly even after it blooms, in order to allow it to maintain its form and strong scent.

4. Lemongrass

A cluster of green spiky lemongrass plants with dark soil underneath them and dark green bushes behind them

(Image credit: Getty Images / Photography by Jeremy Villasis)

For those who are trying to repel mosquitos from their backyards as well as ants, lemongrass is worth trying.

“Lemongrass contains citronella, which is a compound with ant-repellent properties. The essential oils from these plants can also be used to make natural ant spray by mixing a few drops with water in a spray bottle,” Sal explains.

“Apply the spray around doorways, windowsills, and any cracks or crevices where ants may enter,” he suggests.

If you’re keeping your spray bottle outside, it’s worth finding one made with a durable material such as glass, such as the LiBa Glass Spray Bottles from Walmart which are BPA-free.

5. Rosemary

A close-up shot of dark green spiky rosemary plants with light purple flowers growing on them

(Image credit: Getty Images / Jasenka Arbanas)

This is another aromatic herb that can be used to freshen up your backyard and enhance your cooking.

Matthew explains, “Rosemary's aromatic oils — camphor and cineole — repel ants while beautifying the garden itself with a great fragrance.”

He says to plant it in sandy, fast-draining soil in full sun, and to stay on top of pruning in order to keep it bushy and to allow it to release more oils.

Ant repellent essentials


To maximize the effectiveness of these ant-repellant plants, Sal suggests grouping several of them together.

“Adding these natural repellents along with good yard maintenance like removing food sources and sealing any entry points is the best approach to controlling ants,” he finishes by saying.

Dealing with ants up high as well as down low? Learning how to keep ants off your hummingbird feeder may also come in useful.

Eve Smallman
Content Editor

Hi there! I’m a content editor at Real Homes. I've been a lifestyle journalist for over five years, previously working as an editor across regional magazines. Before this, I graduated from Nottingham Trent University a degree in journalism, along with an NCTJ gold diploma. I love running, decorating my rented Victorian home, and discovering new cheeses. For Real Homes, I specialize in interior design, trends and finding the best viral buys.