How to Get Rid of Fruit Flies: Find the Source First

Illustration: a jar trap with a paper funnel beside the sink, and the fruit bowl going into the fridge.
To get rid of fruit flies, find and remove what they’re breeding in: overripe produce, unrinsed recycling, a sour mop, the trash or a drain. Then catch the adults in a jar of cider vinegar with a drop of dish soap, or one of the other DIY traps below. It has worked when no new flies appear for 10 days, one full life cycle.
Cost: about $1–6 in supplies. Time: about 1–2 weeks. Difficulty: moderate. Call a pro if flies keep hatching after you’ve cleared every source you can find, or they’re breeding somewhere you can’t reach, such as a floor drain, a broken drain line or the space under a built-in appliance.
This guide covers telling fruit flies from other small flies, finding the source, four DIY traps, which plan fits your home and what it costs. We haven’t run our own trials; it rests on University of Kentucky, University of Maryland, Nebraska and Texas A&M extension guidance and store list prices.
Saw fruit flies tonight? Fridge the ripe fruit, take out the trash and recycling, and wring out or replace any sour sponge. Set one vinegar jar (see the DIY traps below) wherever flies gather, and tape a clear bag over the sink drain until morning. Skip the bug spray.
What Works and What Doesn’t Against Fruit Flies
Removing the source and trapping the adults works; spraying doesn’t.
| Method | Works? | Cost | Main limitation |
|---|---|---|---|
| Removing ripe produce, rinsing recycling | Yes, the core of the plan | Free | One forgotten banana restarts the cycle |
| Vinegar jar with a drop of dish soap | Yes, for the adults | About $1.29 vinegar | Catches adults, not larvae |
| Store-bought fruit fly trap | Yes, same principle | $5.59 for 2 | Costs more than a homemade jar |
| Scrubbing a drain that tested positive | Yes, when the drain is the source | Free to a few dollars | Bleach and drain cleaner are largely ineffective (Texas A&M) |
| Household fly spray | Only the flies you hit | Varies | Leaves nothing to stop the next hatch (Nebraska) |
| Pro treatment | Rarely needed | $100–$175 | Uses the same baits and traps you would (Fixr) |
Are They Fruit Flies, Gnats or Drain Flies?
Fruit flies are about 1/8 inch long, tan in front and dark at the rear. The common kinds have bright red eyes, which you can check with a magnifier or a phone camera zoomed in.
The easier tell tonight is where they gather:
- Fruit flies hover around the fruit bowl, the trash and open drinks.
- Fungus gnats are slender and dark and hover around houseplant soil; drying the soil is how to get rid of fungus gnats.
- Drain flies are fuzzy, with moth-like wings, and rest on walls near sinks; scrubbing the drain is how to get rid of drain flies.
One catch: a less common dark-eyed fruit fly breeds in drains, so a dark-eyed fly by the sink can still be a fruit fly. The fix is the same either way: find the source. The guide to getting rid of gnats compares all three.
Are Fruit Flies Harmful? Do They Bite?
Fruit flies don’t bite, and University of Minnesota Extension says they generally aren’t considered a health problem. They’re a nuisance because of their numbers.
They do land on food, and Texas A&M AgriLife says they can spread bacteria. Throw out anything with larvae in it.
Where Do Fruit Flies Come From?
They ride in as eggs or larvae you can’t see, on produce from the store or garden. Adults also slip in through screens and door gaps when they smell food, and they peak in late summer and fall.
A female can lay about 500 eggs (University of Kentucky), which is why a few flies can turn into a lot so quickly.
Step 1: Find the Fruit Fly Breeding Source
All a fruit fly needs to breed is a moist film of fermenting material. Check the kitchen first, then the rest of the house:
- Produce left out, plus onions and potatoes stored out of sight.
- Trash cans, especially a wet bottom under a leaky liner.
- Recycling with unrinsed bottles and cans.
- Mops, rags and sponges that smell sour.
- Juice spills under the fridge and its drip pan.
- The garbage disposal and drains.
- Loosely capped vinegar, juice, wine or beer, home brewing, canning and the compost pail.
Don’t stop at the first rotten banana. The University of Kentucky warns that one rotting potato at the back of a closet, or juice spilled under the refrigerator, can keep a whole infestation going.

Illustration: three easy-to-miss breeding spots, a forgotten potato, unrinsed recycling and a mop left sitting in dirty water.
How to Test a Drain for Fruit Flies
Tape a clear plastic food storage bag over the drain or disposal opening overnight. If flies are breeding inside, the new adults end up in the bag. No tools, and nothing to take apart.

Illustration: a clear bag taped over the sink drain at night, and a few small flies caught inside it by morning.
Step 2: Get Rid of Fruit Flies in the Kitchen at the Source
This step is how to get rid of fruit flies in the house for good:
- Eat, toss or refrigerate ripe produce, or keep it in a sealed container or zip bag.
- Empty the trash and wipe out the bottom of the can.
- Rinse recycling and take it outside every few days.
- Freeze compost scraps or use an outdoor bin.
- Clean the garbage disposal.
- Wring out mops, sponges and dishcloths and let them dry fully. Replace any that still smell sour.
- Wipe the counters and rinse dishes left in the sink.
If the bag test caught flies, the drain itself is the source. Texas A&M AgriLife says bleach and drain cleaner are largely ineffective against the slimy film flies breed in, and boiling water alone won’t remove it. You have two options:
- Scrub: work a stiff brush down the pipe as far as it reaches, then flush with hot to boiling water.
- No scrubbing: use a drain treatment made to break down that film. It usually takes repeat doses over several weeks.
Bag-test the drain again afterward.
DIY Fruit Fly Trap: 4 Ways to Make One
Traps catch the adults; only cleaning stops new ones. Colorado State Extension says no fly trap gives satisfactory control on its own, so set these after Steps 1 and 2. All four use a small jar or glass and bait that smells like fermenting fruit:
- Vinegar and dish soap. Pour about an inch of apple cider vinegar into a jar and add a drop of dish soap. The soap breaks the surface tension, so landing flies sink and drown. Leave it open.
- Paper funnel. Roll a sheet of notebook paper into a cone, set it in the jar point down, and bait with a few ounces of cider vinegar or a slice of banana. Flies find their way in and can’t find the way out (University of Kentucky).
- Plastic wrap. Cover a jar of cider vinegar with plastic wrap and poke a few holes in it with a toothpick (Nebraska Extension). Good for a spot where a funnel would get knocked over.
- Red wine or banana and beer. Colorado State lists red wine and a mashed banana and beer mix as baits that are highly attractive to fruit flies. Use the last inch in a bottle, or mash an overripe banana with a splash of beer, and top with a paper cone.
| Trap | Bait | Cost | Good to know |
|---|---|---|---|
| Vinegar and dish soap | Cider vinegar, drop of soap | About $1.29 for a bottle that makes several | Fastest to set up; flies drown as they land |
| Paper funnel | Cider vinegar or banana slice | Pennies | Catches flies alive; empty it outdoors or into soapy water |
| Plastic wrap | Cider vinegar | Pennies | Spill-resistant on a crowded counter |
| Red wine or banana and beer | Leftover wine, or banana and beer | Pennies if you have them | Good when you’re out of cider vinegar |
Cider vinegar: Target list price for 16 fl oz, October 1, 2026, before tax.
How many and where: put one jar wherever you see flies (University of Kentucky), such as by the fruit bowl, the sink and the trash. A jar that fills faster than the others is probably near the source. With a toddler or a cat, pick spots they can’t reach or knock over.
A store-bought fruit fly trap works on the same principle if you’d rather not make one.
Step 3: Keep Trapping and Close the Gaps
Eggs laid before you cleaned keep hatching for one more life cycle, which takes 8 to 10 days (University of Maryland Extension). Keep a jar out and check it every day or two.
You’re done when no new flies show up for 10 days. Plan on 1 to 2 weeks in total.
- Keep ripe fruit in the fridge until then. One forgotten banana can start a new round.
- Fix torn screens and keep outside doors closed; door sweeps help too.
Renting? Report leaks, broken drains, torn screens or missing door sweeps to your landlord in writing.
Why Do Fruit Flies Keep Coming Back?
It’s almost always one of these, even after a thorough clean:
- A source you haven’t found. Traps catch adults, not larvae. Check the pantry, the drip pan, under appliances, the basement recycling and every drain (bag test).
- Eggs still hatching. Give it the full 10 days.
- New produce bringing in a new batch.
- The wrong fly. A new wave without red eyes is probably fungus gnats or drain flies, which vinegar traps won’t fix.
Fruit Fly Spray or an Exterminator: Usually Neither
Usually neither. Nebraska Extension says no insecticide is needed to eliminate fruit flies. A regular household fly spray (pyrethrins) kills only the flies present when you spray and leaves nothing behind to stop the next hatch. So the best fruit fly killer is a vinegar trap, and with kids or pets at home there’s no reason to spray at all. If you do, follow the label.
Which Plan Fits Your Situation
| Situation | Plan | Why |
|---|---|---|
| Flies around the fruit bowl | Fridge the fruit, one jar by the bowl | Overripe produce is the usual source. |
| Flies by the sink, nothing in the bowl | Bag-test the drain, then scrub it | The drain itself may be the source. |
| Toddler or cat at home | Jars up high or out of reach; no spray | There’s no reason to spray with kids or pets at home. |
| You rent | Report leaks, broken drains and torn screens in writing | You can’t fix those yourself. |
| Flies without red eyes that ignore vinegar | Switch plans | Probably fungus gnats or drain flies. |
| Still hatching after two weeks | Call a pro or a plumber | The source is probably out of reach. |
What It Might Still Cost
| Item | Typical cost |
|---|---|
| Apple cider vinegar, 16 fl oz (makes several traps) | $1.29 |
| Store-bought fruit fly trap, 2-pack | $5.59 |
| Pro fruit fly treatment | $100–$175 |
DIY: Target list prices, October 1, 2026, before tax; dish soap, jars and plastic wrap come from your kitchen.
Pro: Fixr (updated January 2025). Fixr says pros typically use baits and traps for fruit flies, the same tools you’d use.
Before You Start: A Quick Checklist
- Check the fly: tan with red eyes means fruit fly.
- Move ripe fruit into the fridge.
- Rinse recycling and take out the trash.
- Wring out or replace sour sponges and mops.
- Bag-test every drain overnight.
- Set one jar wherever flies gather.
- Wait 10 days with no new flies before you call it done.
When to Call a Pro
Call a pro, or a plumber, only when:
- You’ve cleaned every source you can find, bag-tested every drain, and flies are still hatching after two weeks.
- The source is out of reach: a floor drain, a broken drain line, cracked tile or under a built-in appliance.
- It’s a food business, where Texas A&M AgriLife notes health departments consider fruit flies unsanitary.
Ask what source they found. A visit that only sprays adults won’t stop the next hatch.
Common questions
A vinegar trap with a drop of dish soap drowns them as they land. It won’t stop new ones hatching until the source is gone.
Throw out anything with larvae in it. For one bad spot on a melon, the University of Kentucky says you can cut away the damaged part and keep the rest, because the larvae feed near the surface.
Apple cider vinegar is the better choice, because its fermenting-fruit scent is what draws them. The extension traps in this guide use cider vinegar, red wine, ripe banana or beer as bait, not plain white vinegar. Out of cider vinegar? Use a mashed banana or a splash of red wine.
The Bottom Line
Find the breeding source, not just the flies: ripe fruit, recycling, a sour mop or a drain. Clear it, set a vinegar jar where they gather, and give it 10 days. Most homes need nothing more than a $1.29 bottle of cider vinegar.
Sources and further reading · 10
- University of Kentucky Entomology: Fruit Flies (ENTFACT-621), revised 3/26 — breeding sites, life cycle, bag test, sprays.
- Nebraska Extension in Lancaster County: Fall Is the Time for Fruit Flies, 2024 — cleanup steps, cider vinegar trap.
- Texas A&M AgriLife Extension: Indoor Flies and Their Control (ENTO-050) — health, traps, drain cleaning.
- University of Maryland Extension: Fruit Flies — size, 8–10 day life cycle, mops.
- University of Wisconsin: Fruit Flies in the Home — traps and pyrethrin sprays.
- Washington State University Pestsense: Fruit Flies — bag test.
- University of Minnesota Extension: Fruit Flies — identification, health.
- Colorado State University Extension: Flies in the Home — lookalike flies, traps.
- Utah State University Extension: Fruit Flies — screens and door sweeps.
- Fixr: Fly Exterminator Cost, updated January 31, 2025 — pro prices.


