I’ve never really liked flies, and I think they’re probably one of the most annoying insects on our beautiful planet. However, I’ve realized that you’ll have to deal with the occasional lone fly if you’re keeping a garden, no matter how disgusted you feel about the insects or how annoying they sound. But what if it’s not an occasional lone fly, and you notice swarms of flies around your garden?
Your garden may have so many flies around it because of pet droppings and animal feces, rotting animals, or dirty garbage cans. You might also notice fly clusters if you have decomposing food waste, compost, and manure in or around the garden.
Decomposing materials serve as perfect breeding and feeding sites for most fly species, so it’s expected they’ll be attracted to your garden if there’s dead or rotting organic matter in the vicinity. In this article, I’ll examine each of these materials in detail and explore the impact flies might have on your garden. I’ll also discuss the most common flies you might find in your garden as well as the best ways to eliminate them from your space.

1. Pet Droppings and Animal Feces
There’s a direct correlation between fly infestations and animal droppings or pet feces. After all, the image of a lone fly or swarm of flies buzzing around poop has become almost a cliché in movies and kids’ shows.
However, these images aren’t just another attempt by Hollywood to dramatize events on screen, and poop in your garden will attract flies. This poop might come from you or your neighbor’s pets, but they might also be droppings from visitors like squirrels and deer—depending on where your garden is located.
These feces serve as a breeding ground for flies who lay their eggs in the nutrient-rich matter. The adult flies also feed on the feces, and any swarm can thrive on a few mounds of animal droppings in a short period.
After all, flies have remarkably short lifespans and lay impressive amounts of eggs in an even shorter period.
Fortunately, you can prevent this problem by cleaning your garden and picking up after your pets as often as possible.
2. Rotting Animals
Another reason your garden might have so many flies around it is if there are rotting animals in or around the area. Decomposing bodies provide the same environment as poop, and flies will swarm a rotting animal corpse for days to feed and reproduce.
These rotting animals–sometimes referred to as carrion–can vary in size from a tiny field mouse to bigger animals like deer. And regardless of the animal’s cause of death, scavengers like flies and maggots will gather around the area.
Locating these animals when they die in enclosed spaces, like under a porch or in a shed, is somewhat easier. The stink is a dead giveaway, and you can locate the offending carrion in minutes.
Unfortunately, you might have trouble identifying why flies plague your garden if the rotting animal is in an open area. The decomposing body might not smell as much, and the fly cluster might be harder to find.
In this case, I’d recommend inspecting every corner of your garden for the offender. You might also need to examine areas around your garden if your space turns up clean.

Still, scavengers like vultures and coyotes might help you find the carrion if you have trouble locating the rotting animal.
You can remove the animal after you’ve found it, but ensure you get every part of the carrion. Some flies will make do with even the most minuscule amounts of decomposing matter, which may cause more problems in the future.
Remember to use gloves and a garbage bag when dealing with decomposing matter, especially dead animals, since they usually carry many diseases.
Ensure you dispose of the carrion appropriately to ensure it doesn’t become a problem later.
3. Open or Dirty Garbage Cans
Garbage cans aren’t necessarily breeding grounds for flies, regardless of what you think. In fact, most garbage cans are relatively safe and are usually only hotspots for bigger scavengers like raccoons and crows.
Open or dirty garbage cans are the problem since they expose decaying organic matter to the open air. You should know that decomposing matter and open air are perfect for fly swarms.
Therefore, while most garbage cans might not draw flies to your garden, an open one might be why there are swarms of flies in your space. These garbage cans provide everything flies need to survive–shelter, food, and a great environment to reproduce.
However, dirty garbage cans can also cause problems, even if closed. These provide similar environments as carrions or feces, and you’ll almost always notice fly clusters around such cans.
Fortunately, you can prevent this problem by closing your garbage cans as often as possible. Hosing off the cans can also help keep them clean and prevent flies from thriving in or around your garbage.
Still, you should treat your trash right and remove them from your property as often as possible.
4. Decomposing Food Waste
Decomposing food waste can be as harmful as open trash in your garden. And while this might not always seem obvious, the waste might be why your garden has so many flies around it. It’s standard practice to throw food waste on grass and gardens as fertilizer.
The natural decomposition process of this organic matter is an excellent way to increase soil nutrients and improve soil quality.
Tossing your food waste in the garden is also a great way to improve the green economy and combat waste. It’s also a great way to cut down on fertilizer costs and reduce the amount of trash you produce.
Ultimately, this practice might benefit your garden and plants but can also lead to fly infestations. Flies are scavengers and an integral part of the decomposition process. They break down organic matter and ensure the food waste becomes compounds that get into the soil.
These flies might not become a problem if you only occasionally throw in decomposing food waste. However, making a habit out of it might turn your garden into a dirty, smelly breeding ground for many fly species.
5. Compost
Humans have been composting for hundreds, maybe thousands of years. In fact, the practice is so beneficial and hassle-free that even the most advanced gardens and farms of the 21st century use compost piles in one form or the other.

Most gardeners and farmers opt for composting as an alternative to dumping decomposing organic matter on their soil. The practice is easy, safe, and requires relatively inexpensive materials.
However, composting is pretty much gathering decomposing organic materials in a pile for future use. Therefore, it might attract scavengers like flies if you don’t contain it well.
These pesky flies might find their way into uncontained compost and thrive in their warm environment. Fly-infested composts can be pretty annoying because it’s common to have compost piles in or around gardens. Therefore, the flies will find their way into your garden and garden area.
Still, composting doesn’t necessarily mean you have to deal with flies and other decomposers. In fact, most correctly-maintained compost piles are barely noticeable and will cause no problems for your plants or garden.
The best way to prevent compost piles from attracting flies to your garden is to keep them as contained as possible.
Maintaining your compost is one of the best ways to keep your garden fly-free and ensure that beneficial composers like worms are in compost piles in the right amounts. In fact, unattended compost piles can not only attract flies and other pests, but it’ll also deplete the nutritional value of the mulch over time.
6. Natural Fertilizers and Manure
Natural fertilizers and manure might also be why your garden has so many flies around it. Manure is mostly poop, and it works by decomposing into essential nutrients that improve soil quality and ensures healthy greens.
Natural fertilizers also contain incredible amounts of manure, usually mixed with wood shavings or other beneficial organic matter. It’s no surprise that manure’s such an integral part of fertilizers. After all, the material is incredibly effective for all kinds of soil.
Still, these materials can draw in flies and other decomposers as part of their natural decomposition process. Therefore, the manure you use as fertilizer might be responsible for the fly swarms you notice in your garden.
An excellent way to prevent this problem is to switch over to something like a 20-20-20 liquid fertilizer as it supplies garden soil with essential nutrients without leaving fly-attracting residue.
However, liquid fertilizers might not always be practical alternatives for some gardeners. In that case, I recommend spreading the manure as much as possible to reduce mounds in the garden.
This method will improve the decomposition rate and reduce the chance that the manure stays out long enough to attract flies.
You might also need to adjust the frequency of application to reduce the number of flies that gather in your garden.
Are Flies Bad for Gardens?
It takes a lot of work and study to grow a successful garden–whether it’s in your backyard or sitting on a few acres of land. I’ve learned that many factors contribute to ensuring your plants stay as healthy as possible, from environmental to biological. Therefore, we must understand just how much the presence of flies might impact your garden and affect plant development.
Flies aren’t bad for gardens, but an infestation might be a nuisance for gardeners and plant keepers. In fact, they are essential decomposers that help to break down organic matter into essential nutrients that improve the soil. Therefore, they’re an important part of your garden’s ecosystem.
However, some fly species might spread illnesses like cholera and typhoid fever. They usually infect humans and pets through bites or by contaminating food and surfaces. Fortunately, they’re relatively easy to manage and control in your garden.
What Types of Flies Affect Gardens?
Flies are one of the most important and diverse species on the planet. And while they might not directly impact your garden or affect plant health, you must learn what species you might find in your space. Most flies affect your garden similarly, but you can tell them apart by size, shape, color, or season.

Here are some of the flies that can affect your garden:
- Hoverflies
- Long-legged flies
- Tachinid flies
- Fruit flies
- Fungus gnats
- Horseflies
- Phoridae flies
- Drain flies
- Black flies
- Robber flies
This list isn’t exhaustive, and you may find fly species in areas where you might least expect them. Fortunately, you can easily distinguish them from other insects since they all share the same general body structure.
How To Get Rid of Flies Around Your Garden
I’ve already gone over some practical ways to prevent fly infestations in your garden. However, you might not always be able to keep your garden and its surroundings as clean as possible to avert fly swarms. Therefore, I thought it’d be fantastic if I went over some excellent methods you could use to get rid of flies around your garden.
Here’s how to get rid of flies around your garden:
- Grow fly-repelling plants.
- Use a cayenne pepper spray.
- Trap the flies with a mixture of vinegar and dish soap.
- Use insecticides.
These methods are excellent for clearing out existing fly infestations in your garden. At this point, keeping your garden might help but will not be as effective. Therefore, you’ll need to eliminate the problem, the flies, to save your garden.
Still, I recommend you clean up your garden and ensure it’s as clean as possible before applying these methods. A neat garden will ensure the flies do not return after eliminating them.
Now let’s explore how each of these methods works.
Grow Fly-Repelling Plants
Some plant species can be a natural repellant for flies in your garden. These plants have unpleasant smells to the insects and will help keep them away from your garden and its surroundings. You can plant or grow them beforehand if you notice many flies around the area.

Some of these fly-repelling plants are catnip and lavender. But you can also grow carnivorous plants like the Venus Flytrap to help control fly swarms.
Ultimately, growing these plants is an excellent idea since you can improve plant diversity in your garden and simultaneously eliminate flies. Some of these fly-repelling plants might also be useful in other ways.
Use a Cayenne Pepper Spray
Cayenne pepper spray is a fast and inexpensive way to remove flies from your garden and around your home. The cayenne pepper can repel flies almost as well as insecticides, and all you need to do is mix some with water.
Spray your plants with the mix; you should notice results in a few days. However, using cayenne pepper spray might not always be effective or practical.
Trap the Flies With a Mixture of Vinegar and Dish Soap
I’m pretty sure you can use vinegar for almost anything at this point. This method is a great way to trap flies, but it does mean you’ll have to deal with a bit of a mess afterward. You’ll need dish soap, a glass, some vinegar, and plastic wrap.
Pour some vinegar into the glass and a few drops of dish soap. Then, cover the glass with plastic wrap. Poke a few holes in the plastic wrap to complete the trap, and you’re set!
Use Insecticides
Insecticides are another way to control fly populations in or around your garden. They work by disrupting the insects’ natural processes and are one of the most effective methods you can use to eliminate flies.
However, there’s a chance they could harm beneficial insects or affect your plant’s well-being. Therefore, you might need to review the insecticides’ active ingredients to ensure it’s safe for garden use.

Final Thoughts
Your garden might have so many flies around it because of decomposing matter in or around the area. These materials might be from dead animals, pet droppings, compost, or even a dirty garbage can.
This article provides all the information you need to understand what impact these flies could have on your garden and how best to control them.