How to Get Rid of Ants in Garden (12 Ways)

A few ants in the garden aren’t a crisis. They aerate soil, break down organic matter, and generally earn their keep. But when colonies start farming aphids on your vegetables, building mounds in your raised beds, or establishing outposts along your foundation, it’s time to intervene. Garden ant control is different from indoor pest control because you’re working with soil, plants, and an ecosystem you don’t want to nuke. These methods target ants without destroying everything else.

1. Sprinkle Cinnamon Around Plants

Ground cinnamon acts as a natural repellent without harming plants. Ants hate the scent, and direct contact disrupts their pheromone communication.

Sprinkle it around the base of plants, along garden bed edges, and near visible ant activity. You can also mix cinnamon with water for a spray to cover larger areas. Reapply after watering or rain. This works especially well in raised beds where you can create a consistent barrier around the perimeter.

2. Scatter Citrus Peels in Garden Beds

Fresh citrus peels (lemon, orange, grapefruit) contain d-limonene, a compound that’s toxic to ants. The strong scent also masks the pheromone trails they use to navigate between the colony and your plants.

Tear peels into small pieces and scatter them around ant trails, near mounds, and at the base of affected plants. Replace every few days as they dry out. For a stronger effect, blend citrus peels with water and spray the mixture directly on trails and around beds.

3. Spread Coffee Grounds

Used coffee grounds create a barrier ants won’t cross. The smell interferes with their scent navigation and the texture makes it physically uncomfortable for them to traverse.

Sprinkle used grounds around plant bases and garden bed perimeters. This also adds nitrogen to your soil as the grounds decompose. Replace weekly or after heavy rain.

4. Apply Diatomaceous Earth

Food-grade diatomaceous earth is a fine powder made from fossilized algae. To us it feels like flour. To ants it’s walking across broken glass. The microscopic sharp edges puncture their exoskeletons, causing fatal dehydration.

Sprinkle a thin line along ant trails, around bed borders, and near mound entrances. Use food-grade only (not pool-grade). It’s non-toxic to people, pets, and plants but devastating to anything with an exoskeleton. Reapply after rain since moisture kills the effectiveness.

5. Use Neem Oil Spray

Neem oil disrupts ant behavior and reproduction without harming your plants. It works as both a repellent and a contact killer, and it’s safe for organic gardens.

Mix 2 tablespoons of neem oil with 1 gallon of water and a few drops of dish soap (helps the oil mix). Spray directly on trails, mounds, and affected plants. Focus on areas where ants are actively farming aphids, since neem also kills the aphids and cuts off that food source. Apply in early morning or evening to avoid sun damage to leaves.

6. Plant Companion Plants That Repel Ants

Mint, tansy, pennyroyal, sage, and garlic all deter ants through their scent or chemical compounds.

Interplant these near vulnerable crops, especially vegetables or flowers that attract aphids. Mint is particularly aggressive and works well as a border plant, though plant it in containers because it spreads like it’s trying to take over the world. This works best as prevention. It won’t eliminate an active infestation, but it discourages new ones from establishing.

7. Apply Beneficial Nematodes

Beneficial nematodes are microscopic organisms that parasitize and kill ants without affecting plants, earthworms, or beneficial insects. Biological control that targets the colony underground.

Mix nematode powder with water per package directions and apply to soil around mounds and garden beds. Water the area thoroughly before and after (nematodes need moisture to move through soil). Most effective in spring and fall when soil temperatures are moderate. Results take 1-2 weeks as the nematodes locate and infect the colony.

8. Pour Boiling Water on Outdoor Mounds

Found the colony? If you can see the mound, boiling water is the most direct approach. Bring a full kettle to a rolling boil and pour slowly into the mound entrance.

One application won’t usually wipe out the entire colony. Deeper chambers may survive. But repeated applications over several days can significantly reduce the population. Combine with outdoor bait stations for the best results.

9. Use Essential Oil Barriers

Concentrated peppermint, tea tree, eucalyptus, and clove oils create scent barriers ants won’t cross. These oils overpower the pheromone trails they use to navigate.

Mix 10-15 drops with 1 cup of water and a tablespoon of dish soap. Spray around garden bed edges, plant bases, and along ant trails. You can also soak cotton balls in undiluted oil and place them near mounds. Reapply every few days or after rain.

10. Block Vegetation and Utility Contact Points

Ants use overhead highways: tree branches touching your roof, shrubs pressed against siding, utility cables running into your house, and drainage pipes that bridge ground to structure.

Trim branches and shrubs so they’re at least 15 cm from your house. Check where cables and conduits enter walls from the garden side. Apply diatomaceous earth or petroleum jelly around these entry points. For outdoor taps and utility installations, seal gaps with caulk and maintain a 30 cm vegetation-free zone around the foundation. Removing access routes forces ants to use ground-level entries you can more easily defend.

11. Replace Water-Damaged Outdoor Wood

Carpenter ants don’t eat wood. They excavate it to build nests, targeting wood that’s already soft from water damage or fungal decay. Rotting fence posts, garden bed frames, and any outdoor timber touching soil are prime real estate for them.

Check for soft spots and discoloration in garden structures. Replace compromised materials with pressure-treated or naturally rot-resistant wood. Use concrete footings to eliminate wood-to-soil contact where possible. Healthy outdoor timber doesn’t attract carpenter ants.

12. Maintain Your Deck to Prevent Rot

Wooden decks are perfect carpenter ant habitat once they start to rot. Ground contact, trapped moisture between boards, and aging wood create ideal conditions for both decay and ant colonization.

Inspect annually for soft spots, especially where posts meet the ground. Apply deck sealant every 2-3 years. Ensure water drains off rather than pooling in low spots. Replace rotting boards before carpenter ants move in. Clear debris from between boards where moisture collects. A maintained deck removes a major ant attractant from your perimeter.