Step by step: how to get rid of fruit flies
- 1
Hunt down the breeding source
Check every place fermenting food can hide: the fruit bowl, bags of potatoes and onions, the pantry floor, under the fridge and stove, the recycling bin and the bottom of the trash can. One rotting potato or a juice spill under the fridge can breed thousands of flies. Look for soft, leaking or moldy produce and sticky residue.
- 2
Throw out or refrigerate ripe produce
Bag and remove anything rotting, and take it outside, not just to the kitchen trash. Eat, refrigerate or freeze ripe fruit. Cut bruised or split spots off fruit you keep, because eggs and larvae stay near the damaged surface.
- 3
Empty and wash the trash and recycling
Take the trash out, then wash the inside of the can with hot soapy water, paying attention to the bottom where liners leak. Rinse bottles, cans and jars before they go in the recycling. Leave the can to dry before you put in a new bag.
- 4
Test the drains overnight
Tape a clear plastic food storage bag over the kitchen sink drain and the garbage disposal opening before bed. If flies are breeding in the pipe, adults will be trapped in the bag by morning. If the bag stays empty, the drain is not your source.
- 5
Scrub any drain that tested positive
Remove the drain stopper and scrub inside the pipe with a stiff drain brush to break up the slimy film the larvae feed on. Run hot water for a minute afterward. For a garbage disposal, scrub under the rubber splash guard, where food film builds up.
- 6
Set apple cider vinegar traps
Pour about 1/2 cup of apple cider vinegar into a jar and add one drop of dish soap so the flies sink. Cover the top with plastic wrap, secure it with a rubber band and poke a few small holes, or roll a paper funnel into the jar. Put one trap wherever you see flies; you should see a catch within a day.
- 7
Replace sponges and dry the mops
Wash damp mops, rags and dish towels, wring them hard and hang them to dry. A sour sponge or a mop left in a bucket can hold enough fermenting film to breed fruit flies. Swap out old sponges.
- 8
Keep trapping for two weeks
Fruit flies go from egg to adult in about a week, so a few will keep appearing for several days after you remove the source. Refresh the vinegar every few days. If the catch is still rising after a week, you have missed a breeding site; repeat the search.
Is it a fruit fly, a fungus gnat or a drain fly?
Fruit flies are tan with red eyes and hang around food and trash; fungus gnats are black, slender and stay near houseplants; drain flies are fuzzy, gray and rest on bathroom walls. The fix depends on which one you have, so look closely at one that has landed before you start.
| Insect | What it looks like | Where you see it | Where it breeds |
|---|---|---|---|
| Fruit fly | About 1/8 inch, tan front and darker rear, usually red eyes, stout body | Fruit bowl, trash, recycling, kitchen sink | Fermenting produce, spills, sticky containers, sometimes drains |
| Fungus gnat | 1/16 to 1/8 inch, black, slender, long legs, looks like a tiny mosquito | Houseplants, windows, around screens and lamps | Damp potting soil |
| Drain fly | Up to about 1/5 inch, fuzzy, gray, wings held like a roof or flat like a moth | Bathroom walls, tubs, showers, basement floor drains | Slime inside drains and overflow pipes |
Texas A&M AgriLife Extension notes that each small indoor fly breeds in different places, so identifying the fly is the first step. If yours are black and circling a plant, read how to get rid of fungus gnats. If they are fuzzy and parked by the shower, go to how to get rid of drain flies. Not sure at all? Our guide to getting rid of gnats in the house walks through all three.
How fast do fruit flies multiply?
Fast enough that a few flies turn into a cloud in about a week of warm weather. Colorado State University’s fact sheet on small fruit flies lays out the timeline:
- Females lay eggs directly on fermenting food or around its edges, and the eggs hatch in 1 to 2 days.
- The larvae feed on the surface of the food for about 5 to 6 days at summer temperatures.
- They then crawl away to a somewhat drier spot to pupate.
- At 85°F, the whole cycle from egg to adult can take as little as 8 days.
Three things follow from that for your kitchen:
- Because larvae leave the food to pupate, wipe the area around a rotten item too: the inside of the fruit bowl, the shelf under the potato bag, the rim and floor of the trash can.
- Warm kitchens speed up every stage, so keep produce in the fridge during hot spells.
- The same fact sheet says an infestation ends when the remaining adults die, about 2 weeks after breeding stops. Colorado State’s Flies in the Home guide suggests eating, covering or refrigerating all susceptible fruit for at least a week while that happens.
Which homemade fruit fly trap works best?
The best trap pairs a strong fermented smell with an entrance flies can get into but not out of. Extension services describe a few versions that work, and they all use things you already have.
| Trap | How to make it | Why it works |
|---|---|---|
| Vinegar and soap jar | Cider vinegar and a drop of dish soap in a jar, covered with plastic wrap with a small hole poked in it | Soap breaks the surface so flies that land sink; the small hole keeps them in |
| Paper cone jar | A few ounces of bait in the bottom of a jar, with a rolled paper cone set in the top, narrow end down | Flies follow the smell down the cone and rarely find the small opening again |
| Ready-made trap | A store-bought trap with a food-based lure | Tidy and spill-proof, but it catches adults only, like the others |
The jar with plastic wrap follows the University of Maryland Extension; the University of Kentucky’s small flies fact sheet describes a paper funnel in a jar baited with a few ounces of cider vinegar. For bait, Colorado State lists cider vinegar, red wine and mashed banana mixed with beer as highly attractive to fruit flies.
- Put each trap right where the flies hover, not across the room. Several small traps beat one big one.
- Refresh the bait every few days and empty used traps outside.
- Throw out a fruit-baited trap after a few days, before the bait itself starts breeding flies.
Why is my fruit fly trap not catching anything?
Usually because the trap is in the wrong place, the flies can get back out, or they are not fruit flies at all. Run through these checks before you give up on it.
- The source is still there. A trap that fills up every day means flies are still hatching nearby. The University of Kentucky notes that killing adult flies usually gives only temporary relief; you have to remove where the larvae live.
- No soap, or holes too big. Without soap, flies land, drink and leave. If you can fit a pencil through the holes in the wrap, make them smaller.
- Competing smells. A trap next to a full fruit bowl or an open trash can loses. Clear the counter so the trap is the strongest smell in the room.
- Wrong fly. Vinegar traps catch fungus gnats from houseplants and drain flies from the shower poorly. If your flies are black and slender or fuzzy and gray, go to our guide to getting rid of gnats in the house to identify them.
Should you spray insecticide for fruit flies?
Usually not: spraying the adults does nothing about the eggs and larvae in the source, so new flies keep emerging. Clean out the source first and use traps for the rest.
The Kentucky fact sheet says that once breeding sites are gone, a pyrethrum-based aerosol can be used to knock down remaining adults, but that the problem continues no matter how often you spray if the source stays. If you do use a spray, pick one whose label allows indoor use in kitchens, keep it off food, dishes and counters, and follow the directions exactly. The EPA points out that the pesticide label is legally enforceable: using a product in a way the label does not allow is against federal law.
How to keep fruit flies from coming back
Keep ripe produce cold, keep containers clean, and keep the screens tight. Fruit flies need only a thin film of fermenting food to start again.
- Store bananas, tomatoes and stone fruit in the fridge once they are ripe, and check onion and potato bags weekly.
- Rinse jars, bottles and cans before recycling, as the University of Maryland Extension advises, and empty the recycling often.
- Take kitchen trash out daily in late summer and fall, and wash the can monthly.
- Keep tight-fitting window screens in good repair; Kentucky recommends 16 mesh.
- Seal home canning, cider, wine and beer containers well, since flies lay eggs under loose lids.
Mistakes to avoid
- Setting traps but leaving the rotting onion, the sticky recycling or the dirty drain that is producing the flies.
- Throwing rotten fruit in the kitchen trash and leaving the bag there overnight.
- Using vinegar without soap or a lid, so flies land, drink and fly away again.
- Stopping after two days; eggs already laid keep hatching for about a week.
- Pouring bleach down the drain, which runs past the slime the larvae live in without removing it.
- Spraying insecticide near open food or on counters, against the label.
- Leaving a banana or wine trap out for a week, until the bait becomes a new breeding spot.
Products that make this easier
Optional. Everything above works with basic supplies; these just save time or effort.
- See it on Amazon
Ready-made trap
TERRO Fruit Fly Trap
A small apple-shaped trap with a food-based lure that sits neatly by the fruit bowl. It catches adults only, so you still need to remove the source.
- See it on Amazon
DIY trap bait
Bragg Organic Apple Cider Vinegar
Raw cider vinegar smells strongly of fermenting fruit, which is exactly what draws fruit flies. Any cider vinegar works; this one is easy to find.
- See it on Amazon
For homemade traps
Ball Regular Mouth Mason Jars (8 oz)
Small jars make neat, stable traps you can set on a counter or windowsill and wash and reuse.
- See it on Amazon
Keeps scraps sealed
OXO Good Grips Easy-Clean Compost Bin
A lidded countertop bin keeps food scraps from becoming a nursery. Empty it every day or two in warm weather, or flies will find it anyway.
As an Amazon Associate, Broombook earns from qualifying purchases. Links open the product on Amazon, where sizes, sellers and prices change.