Found almost everywhere on the planet, flies inhabit forests, open fields, busy city streets, waste sites, homes and agricultural spaces. Their ability to thrive in such diverse environments comes largely from their incredibly flexible diet. Unlike many insects that rely on specific foods, flies consume a wide range of organic materials, including decaying matter, plant fluids, animal waste and human foods. Understanding what flies eat helps explain why they are so persistent and how they can spread rapidly in homes and outdoor spaces.
Flies lack chewing mouthparts, which means they cannot bite or chew solid food. Instead, they use a specialized feeding method: liquefying food before ingesting it. When they land on solid foods, flies regurgitate digestive enzymes that dissolve the food into a liquid form. This ability allows them to exploit numerous food sources that other insects cannot. It also makes them efficient decomposers in nature but troublesome pests in human environments.
This detailed guide explores 20 foods flies consume in nature and indoors. These insights help explain fly behavior, attraction points, and why managing their food sources is key to controlling infestations.
Understanding the Fly Diet

Flies are saprophagous insects, meaning they feed primarily on decaying organic matter. Their digestive system is specialized for breaking down liquefied food rather than chewing solids. When a fly lands on food, it secretes enzymes that dissolve the material, then sucks up the liquid using a sponge-like mouthpart called a proboscis. This feeding mechanism allows flies to exploit foods in various states of decay.
In nature, flies help break down dead animals, animal waste, plant debris and rotting fruit. Their diet plays a significant ecological role by accelerating decomposition, recycling nutrients and supporting microbial communities. Although flies carry undesirable associations, they are important contributors to nutrient cycling in forests, fields and wetlands. Many plants even benefit from fly pollination, especially species that emit strong odors mimicking decay.
Indoors, flies take advantage of human habits: spilled drinks, uncovered foods, trash, pet waste, dirty drains and sugary residues. Their attraction to moist, fermenting or decaying materials makes kitchens, trash bins and drains ideal feeding grounds. By understanding what flies eat, homeowners can better prevent infestations and reduce fly breeding opportunities.
20 Foods Flies Consume in Nature and Indoors
1. Rotting Fruit
Rotting fruit is one of the most attractive food sources for flies, especially fruit flies and houseflies. As fruit decomposes, it releases strong odors and natural sugars that flies easily detect. The moisture content provides an ideal liquid-based feeding source.
In nature, rotting fruit helps sustain fly populations in orchards, forests and gardens. Fruit flies breed in fermenting fruit, laying eggs that hatch into larvae that feed on the decaying material. This allows fly populations to grow rapidly during warm seasons.
Inside homes, overripe bananas, apples, grapes or forgotten fruit in trash bins create perfect conditions for infestations. Sealing fruit properly or storing it in refrigerators helps prevent fly attraction.
2. Decomposing Meat
Decomposing meat produces powerful scents that attract flies from long distances. Blowflies and carrion flies are especially drawn to dead animals in nature, where they act as early colonizers in the decomposition process. Their larvae, known as maggots, help break down tissue quickly.
Flies detect sulfur compounds released during decay, guiding them to carcasses in forests, fields or roadways. These protein-rich sources support fly development and reproduction. Maggots thrive on softening flesh, accelerating the natural breakdown cycle.
Indoors, spoiled meat in trash cans or improperly stored leftovers attracts flies instantly. Keeping meat sealed and disposing of waste promptly can prevent infestations.
3. Sugar and Sweet Liquids
Flies love sugary foods because they provide immediate energy. Drinks like soda, juice, wine and sugary syrups attract flies quickly due to their strong, sweet aromas. Spilled or fermenting liquids become feeding hotspots in kitchens and outdoor dining areas.
Fruit flies thrive near alcohol and fermentation. Even a few drops of wine or beer can support dozens of flies. Their tiny size allows them to fit into bottle openings, drains and recycling bins. Once inside, they lay eggs near liquid residues.
In nature, flies consume plant nectar, honeydew and sap for sugar. Indoors, wiping spills promptly prevents them from establishing breeding sites.
4. Animal Feces
Flies are strongly attracted to feces of all kinds: dog waste, livestock manure, bird droppings and wildlife scat. Feces are rich in bacteria and organic matter that flies feed on. Houseflies and blowflies often lay eggs directly on feces, where larvae hatch and feed immediately.
On farms and pastures, manure becomes a key food and breeding site for flies. Large piles support massive larval populations, making fly control difficult without proper management. In natural environments, flies play a role in decomposing waste and returning nutrients to the soil.
At home, pet waste in yards or litter boxes can attract flies if not cleaned regularly. Proper disposal is essential for preventing infestations.
5. Garbage and Food Scraps
Trash bins provide an ideal mixture of decaying food, moisture and warmth—exactly what flies need to feed and reproduce. Houseflies detect garbage smells through chemical cues, arriving soon after waste is exposed.
Inside trash cans, flies feed on everything from spoiled vegetables and meat to liquids and sticky residues. They lay eggs along the edges, producing larvae that thrive on decomposing materials. Open or overflowing cans become major breeding sites.
Keeping lids closed, using liners and cleaning garbage cans regularly significantly reduces fly attraction.
6. Decaying Vegetables
Rotting vegetables release odors that attract flies, especially when moisture content increases. Potato skins, wilted lettuce, moldy carrots and spoiled herbs all become feeding opportunities. The breakdown process softens vegetables, making them easier for flies to dissolve and ingest.
Vegetable waste in compost bins or garden piles naturally supports fly populations. While beneficial for decomposition, unmanaged compost can create swarms. Proper layering and covering help reduce fly activity.
Indoors, refrigerator drawers with forgotten vegetables or produce left too long on countertops quickly draw flies.
7. Honey and Nectar
Flies consume nectar and sugary plant liquids in nature, just like bees and butterflies. They visit flowers not for pollination, but to feed on accessible liquid sugars. Some plants rely on flies for pollination, especially species with strong odors or open flower structures.
Honey and syrups also attract flies. A small drop of honey left on a counter can feed several flies. The sticky nature of these foods makes them long-lasting feeding stations.
In gardens, flies help pollinate certain flowers, contributing to plant reproduction while feeding on nectar.
8. Alcohol and Fermented Liquids
Fermenting liquids like beer, wine, vinegar and kombucha attract fruit flies and houseflies. The yeast activity and fermentation scents draw them instantly. Fruit flies often breed near alcohol residue because it provides both food and moisture for larvae.
Bars, restaurants and recycling centers are especially prone to fly activity around empty bottles, sticky spills and fermenting residues. Even a bottle cap with leftover liquid can attract dozens of flies.
In nature, flies feed on fermented sap or overripe fruit, playing a role in natural fermentation processes.
9. Pet Food
Pet food left in bowls becomes a feeding site for flies. Wet cat or dog food dries slowly, giving flies plenty of time to feed and lay eggs. Even dry kibble attracts flies if it absorbs moisture or becomes coated in grease or saliva.
Outdoors, spilled birdseed or livestock feed also draws flies. Feeders and barns often have residues that provide nutrient-rich surfaces for feeding. Pet food bowls should be cleaned frequently to prevent attraction.
Fly larvae sometimes develop inside forgotten wet pet food, leading to indoor infestations if not managed properly.
10. Dead Insects
Flies readily consume the bodies of dead insects. In natural environments, they feed on decomposing beetles, spiders, ants and other insect remains. These bodies provide protein and moisture for both adult flies and developing larvae.
Indoors, spiders often trap insects that then become food for flies after drying. Flies also gather around light fixtures where insects die frequently. Even small insect fragments can sustain fly populations.
This scavenging behavior showcases their ecological role as decomposers and recyclers.
11. Spilled Dairy Products
Dairy products like milk, yogurt, cream and cheese attract flies due to their strong odors and high fat content. When spilled, dairy decomposes quickly, becoming especially appealing. Houseflies gather around souring dairy to feed on the liquids and enzymes.
In kitchens, dried milk residues or cheese crumbs provide long-lasting food. Cleaning spills promptly helps prevent fly attraction. Flies may even feed on the crust from old dairy-based sauces.
In nature, flies may consume dairy-like animal secretions and fermented plant liquids that mimic dairy nutrients.
12. Bread and Starches
Moist bread, cooked rice, pasta and other starchy foods attract flies when they begin to ferment or soften. Flies detect yeast fermentation, which produces strong scents. Bread soaked in liquid becomes especially attractive.
In nature, starches are less common, but flies feed on plant sap and fermenting grain. Indoors, bread crumbs under appliances or in trash bins turn into food sources over time.
Stored grains and cereals also draw flies if they become humid or moldy, supporting both adult feeding and larval development.
13. Sap and Plant Fluids
Flies feed on sap leaking from trees, stems or fruit. Sap provides sugar, minerals and moisture. In forests, flies gather around damaged bark or plant wounds where sap flows freely.
Certain sap-feeding behavior helps plants by removing excessive exudate, but flies can also spread plant diseases as they move from one sap source to another.
Indoors, fruit and plant juices from damaged produce in trash bins or counters attract flies quickly.
14. Mold and Fungi
Mold and fungi create moist, nutrient-rich surfaces perfect for fly feeding. Flies scrape up fungal growth from bread, fruit, walls or damp corners. Fungus flies and drain flies depend heavily on mold as their main diet.
In nature, fungi growing on rotting logs or leaf litter support large fly populations. Fungal decomposition progresses faster when flies feed on it, helping recycle organic matter.
Homes with moisture issues, leaks or old food become hotspots for mold-feeding flies.
15. Blood and Body Fluids
Flies are attracted to blood because it contains proteins and minerals. After animal injuries, slaughterhouse waste or predator kills, flies gather quickly to feed. Blowflies are especially responsive, arriving within minutes.
In homes, even tiny drops of blood from meat preparation attract flies. They feed on raw meat juices and surfaces contaminated with bodily fluids.
This behavior contributes to disease transmission, making sanitation extremely important.
16. Fish and Seafood
Fish and seafood release strong odors as they decay, attracting flies immediately. The high protein and moisture content make them ideal for feeding and breeding. Even small scraps or liquids from seafood preparation lure flies.
Fish markets and coastal environments often have dense fly populations due to constant access to seafood residues. Flies feed heavily on fish slime, entrails and discarded flesh.
Indoors, garbage containing fish bones or skins becomes a major attractant if not sealed properly.
17. Soil Rich in Organic Matter
Certain flies, such as fungus gnats, feed on microorganisms and decomposed plant matter within soil. Moist potting soil with high organic content becomes a feeding site for larvae and adults.
Indoor potted plants are common locations for gnat infestations. Overwatering encourages microbial growth, which feeds larvae.
In nature, soil rich in decomposing leaves and roots sustains fly species that depend on microbe-rich organic matter.
18. Eggshell Residue
Flies feed on traces of egg residue left on cracked shells or in trash bins. Egg proteins break down quickly, producing scents that flies detect easily. Even clean-looking shells can attract flies if residue remains.
In compost piles, eggshell surfaces support fly larvae that feed on surrounding organic waste. Indoors, egg cartons or plates with dried egg can draw flies.
Egg residue becomes particularly attractive during warm weather when decomposition accelerates.
19. Dirty Drains
Drains contain organic sludge formed from food particles, grease, soap and hair. Drain flies specialize in feeding on this gelatinous buildup. Houseflies and fruit flies also feed on liquids that accumulate in pipes.
Kitchen sinks, bathroom drains and floor drains are common breeding sites. Flies lay eggs in the slime, where larvae feed until pupation.
Regular drain cleaning reduces fly populations significantly, especially in humid climates.
20. Moisture and Liquids (Not Food but Essential)
Although not a “food,” moisture is vital to a fly’s ability to eat. Because flies suck liquid rather than chew, they depend on water sources to help dissolve food and stay hydrated. Damp surfaces enable them to digest thicker materials.
Flies gather near condensation, wet cloths, mops, leaky pipes and pet water bowls. Even small droplets support their feeding behavior.
Managing moisture reduces fly survival, making it a key part of preventing infestations.
FAQs About What Do Flies Eat
What do flies eat most often?
They commonly eat rotting fruits, decaying meat, garbage, sweet liquids and organic waste.
Do flies eat solid food?
No. They dissolve solid foods with enzymes and then drink the liquid.
Do flies eat blood?
Some species consume blood, especially after injuries or meat preparation.
Do flies eat poop?
Yes. Feces is one of their primary food sources in nature and urban areas.
Why are flies attracted to fruit?
Fermenting fruit releases strong sugars and alcohol-like chemicals that flies detect easily.
Do flies eat pet food?
Yes. Both dry and wet pet food attract flies due to moisture and scent.
Do flies eat mold?
Some species feed heavily on mold, especially fungus gnats and drain flies.
What smells attract flies the most?
Rotting food, decaying meat, fermentation, sugars and strong organic odors.
Do flies eat dead insects?
Yes. They scavenge insect bodies as a protein source.
How do flies eat?
They regurgitate enzymes onto food, liquefy it, then use their proboscis to suck it up.
Final Thoughts
Flies survive by consuming a wide variety of organic materials, from rotting fruit and decomposing meat to garbage, feces, plant fluids and household residues. Their ability to feed on both natural and human-related waste makes them highly adaptable, allowing them to thrive in almost every environment. Understanding what flies eat helps homeowners control infestations and appreciate the ecological role flies play in decomposition. By managing food sources, moisture and sanitation, it becomes easier to reduce fly activity and maintain cleaner, healthier spaces.