How to Keep Rats Out of Your Yard and Garden
Part of: Outdoors and garage

- Difficulty
- Medium
- Time
- A weekend for the setup, then regular upkeep
- Tools
- Sealed bins, hardware cloth, traps, a rake and lidded trash cans
- Call a pro if
- You see rats repeatedly despite cleanup, find burrows near the foundation, or suspect an infestation inside the home.
In this guide
- Wear protection
Rats settle where they find food, water and shelter, and a yard that offers all three will keep them. Remove what attracts them and block their shelter, and they move on. How to keep rats out of your yard starts with food, storing pet food, birdseed and animal feed in sealed metal containers.
1. Lock down food sources
1. Store pet food, birdseed and animal feed in sealed metal containers.
2. Pick up fallen fruit and harvest ripe produce promptly.
3. Feed pets indoors or remove bowls right after meals.
4. Easy food is the number one reason rats stay.
2. Secure trash and compost
1. Use trash cans with tight, locking lids.
2. Keep compost in a sealed bin, not an open pile.
3. Avoid composting meat, dairy and greasy scraps.
4. Rinse cans regularly so residue does not attract scavengers.
3. Remove shelter and hiding spots
1. Clear brush piles, stacked lumber and dense ground cover.
2. Keep firewood raised and away from walls.
3. Mow regularly and trim overgrown areas.
4. Fewer hiding spots mean fewer places for rats to nest.
4. Seal structures and gaps
1. Block gaps under sheds and decks with hardware cloth buried a few inches deep.
2. Seal holes around pipes, vents and foundations.
3. Repair damaged vents and screens.
4. Rats squeeze through small openings, so seal thoroughly.
5. Manage water sources
1. Fix dripping spigots and irrigation leaks.
2. Empty birdbaths, pet bowls and standing water at night.
3. Improve drainage in soggy spots.
4. Rats need water daily, so remove it and they struggle.
6. Trap when needed
1. Set snap traps along walls, fences and runways.
2. Bait with peanut butter and secure the trap firmly.
3. Check traps daily and dispose of catches with gloves.
4. Trapping controls a small problem before it grows.
7. Stay vigilant
1. Watch for droppings, burrows and gnaw marks.
2. Act fast at the first sign before numbers grow.
3. Keep up the cleanup and sealing through every season.
4. Consistency is what keeps a yard rat-free long term.
8. Protect the garden itself
1. Fence vegetable beds with hardware cloth where practical.
2. Clear crop residue and weeds at the end of each season.
3. Raise compost and storage off bare soil where you can.
4. A tidy garden offers rats far less food and cover.
Common mistakes
- Leaving pet food or birdseed accessible overnight, which feeds rats daily.
- Using open compost piles with food scraps, a reliable rat magnet.
- Letting brush and lumber pile up against fences and sheds.
- Setting a few traps while ignoring the food and shelter that keep rats coming.
FAQ
What attracts rats to a yard?
Food, water and shelter. Fallen fruit, pet food, open compost, birdseed, clutter and standing water are the biggest draws. Remove those and rats have little reason to stay.
Are rats in the yard dangerous?
They can carry disease and contaminate soil and surfaces with droppings. They also chew wiring and structures. Keep them out of the yard and away from your home's foundation.
How do I keep rats out of my garden?
Harvest ripe produce promptly, clear fallen fruit, fence beds with hardware cloth where practical, and remove nearby shelter like brush piles and dense ground cover.
Do rats come out during the day?
Rats are mostly nocturnal, so daytime sightings often mean a large or bold population. If you see them by day, step up trapping and cleanup quickly.
Related guides
- How to Keep Deer Out of Your Garden: Learn how to keep deer out of your garden: fence smart, choose plants deer avoid, use repellents that work,...
- How to Keep Raccoons Out of Your Yard: Learn how to keep raccoons out of your yard: lock down trash and pet food, block den sites, and use light and...
- How to Keep Birds From Nesting on Your Porch: Learn how to keep birds from nesting on your porch: remove nests legally, block ledges, and use humane...
- How to Lay a Greenhouse Base: Learn how to lay a greenhouse base: level the ground, set a firm edging or slab pad and anchor the frame...
- How to Remove a Tree Stump Safely: Learn how to remove a tree stump safely: check the utilities, dig around the roots, cut them, rock the stump...
