Ants are a tricky pest - some are harmless, and often they're a sign of other detrimental pests, like aphids, rather than a problem themselves. If you want to get rid of ants in the garden, however, there are several different methods you can try. Here are 7 tricks to help keep pesky ants away.

1. Vinegar. Vinegar has a low pH that isn't good for ants. If you know the location of a problem ant hill, pour vinegar directly onto the center of the mound until the soil is saturated. Alternatively, you can pour the vinegar in a ring around your garden or infested plants to form a barrier the ants won't want to cross.

2. Boiling water. If you know where the ant hills are and you want to kill the ants rather than just deter them, pour boiling water into the center of the hill several days in a row. This ought to kill the colony or at least greatly reduce its size.

3. Cinnamon. Cinnamon has a number of uses in the garden but you probably didn't know ant control was one of them. Many species of ants hate ground cinnamon and will not walk on it if they can help it. Buy a large quantity in bulk and pour it out in a thick line around your garden to form a barrier.

4. Beneficial nematodes. Some nematodes are parasites that kill ants and other pests very efficiently. You can buy and introduce these beneficial nematodes into the soil yourself.

5. Beneficial plants. Catnip, chrysanthemum, garlic, and tansy have all been known to have ant repelling properties, and planting them around the garden should help drive ants away. Marigolds sometimes attract ants, and these can be planted far from more important plants as a "trap crop."

6. Lemon spray. Fill a spray bottle with water and several drops of pure lemon juice to create a spray that should drive away ants without making your plants smell strange.

7. Coffee grounds. Ants don't like coffee, but luckily plants do. Scatter your used coffee grounds around the garden to deter ants and add much needed nutrients to the soil in one go.

Liz Baessler
Senior Editor

The only child of a horticulturist and an English teacher, Liz Baessler was destined to become a gardening editor. She has been with Gardening Know how since 2015, and a Senior Editor since 2020. She holds a BA in English from Brandeis University and an MA in English from the University of Geneva, Switzerland. After years of gardening in containers and community garden plots, she finally has a backyard of her own, which she is systematically filling with vegetables and flowers.