How to Get Rid of Drain Flies (What Actually Works)
Table of Contents
Drain flies come from the film of organic slime coating the inside of your pipes, and that’s the only place worth treating. The adults you swat are a symptom. Remove the film with a stiff brush and an enzyme drain cleaner and the flies stop coming, usually within one to three weeks. Bleach, boiling water, and chemical drain openers don’t remove that film, which is why they keep coming back.
The short version
- What they are: drain flies, also called moth flies, family Psychodidae. About 1/8 in (3 mm) long and fuzzy.
- Where they breed: the gelatinous film inside drains, traps, and pipes. Not in standing water.
- What doesn’t work: bleach, boiling water, and chemical drain openers. They pass through without removing the film.
- What works: mechanical scrubbing to break up the film, then an enzyme drain cleaner to digest what the brush missed.
- How long: 1 to 3 weeks. Egg to adult takes 8 to 24 days depending on temperature.
- Traps: useful for finding the source drain, useless for solving the problem.
Are drain gnats and drain flies the same thing?
Mostly, yes. “Drain gnat” is what people call them, and in almost every case the insect is a drain fly.
Drain flies belong to the family Psychodidae and are also called moth flies. UC IPM describes them as about 1/8 in (3 mm) long, with wings covered in fine hairs that give them a moth-like look. They don’t fly well. They tend to sit on the wall near a sink and move in short hops when disturbed.
Fungus gnats are a different insect. They’re slender, dark, and they breed in damp potting soil, so they hover around houseplants rather than drains. If the insects appear when you water your plants, you have fungus gnats and cleaning your drains won’t help. If they appear near a sink, shower, or floor drain, you have drain flies.
Fruit flies are a third possibility. They’re rounder, tan, and they gather around ripe fruit and recycling bins rather than resting on bathroom walls.
Why do you have drain flies?
Because there’s something for them to eat inside your pipes.
Every drain slowly accumulates a layer of gelatinous organic film on the pipe walls. It’s a mix of soap residue, skin cells, hair, food particles, and the bacteria that live on all of it. Plumbers call it biofilm. Drain flies call it a nursery.
Penn State Extension puts it plainly: the gelatinous organic deposits that accumulate in drains provide an ideal breeding site. Females lay eggs directly on that film, the larvae eat it, and the cycle repeats. This is the same buildup behind a slow-draining shower and the same reason a garbage disposal starts to smell.
The film survives almost everything people pour down a drain. That’s the whole problem in one sentence.
ℹ️ Standing Water Is Not the Issue
Drain flies don’t breed in water. They breed in the moist organic film on the pipe wall. Pouring out standing water or running the tap won’t remove the breeding site, and a perfectly dry-looking drain can still be full of it.
Does bleach kill drain flies?
Not for more than a few days. This is the single most common mistake, and it’s worth understanding why it fails.
UC IPM addresses it directly. It notes the common misconception that pouring boiling water or bleach down a drain will control these flies, then states that these treatments don’t remove the organic film within the drain, and provide at best short-term control.
Here’s the mechanism. Bleach is a liquid. You pour it in, it runs down the middle of the pipe, and it exits. It contacts the film briefly and unevenly, and it doesn’t lift it off the wall. Any adults and larvae it touches die. The eggs and larvae embedded in the film a few inches up the pipe wall don’t, and neither does the food supply.
Within a week you have new adults and you conclude the bleach “wore off.” It didn’t. It never addressed the breeding site.
Boiling water fails for the same reason, with a bonus risk: repeated boiling water can damage PVC joints and is a poor idea for older plumbing.
Does Drano kill drain flies?
Not reliably, and it’s the wrong tool. Chemical drain openers are formulated to dissolve clogs made of hair and grease, using caustics or oxidizers to break them apart.
That’s a different job from stripping a thin biological film off the full inner circumference of a pipe. UC IPM’s position on chemical control generally is that it’s unnecessary for moth fly management, because control is only temporary unless the larval development sites are found and removed.
Chemical openers also have real downsides. They can damage older pipes, they’re hazardous to handle, and they aren’t septic-safe. If you’re on a septic system, see our guide to septic-safe drain treatment before pouring anything caustic.
| Treatment | Kills adults | Removes the film | Lasting result |
|---|---|---|---|
| Bleach | Some, on contact | No | No |
| Boiling water | Some, on contact | No | No |
| Chemical drain opener | Some, on contact | No | No |
| Stiff brush | No | Yes, where it reaches | Partial |
| Enzyme drain cleaner | No | Yes, over repeat use | Yes |
| Brush plus enzyme cleaner | No | Yes | Yes |
How do you actually get rid of drain flies?
Two steps, in this order: break the film up mechanically, then digest what’s left. Neither one alone does the whole job.
How to Get Rid of Drain Flies
Find the right drain
Tape a piece of clear packing tape sticky-side down over each suspect drain overnight, leaving a small gap for air. Check in the morning. The drain with flies stuck to the tape is your breeding site.
Scrub the pipe walls
Work a stiff-bristled drain brush as far into the drain as it reaches and scrub the walls, not just the opening. You are trying to physically break the film loose. Penn State recommends a stiff wire brush for exactly this.
Flush the loosened debris
Run warm water for a minute to carry away what the brush knocked free. Do not use boiling water on PVC.
Apply an enzyme drain cleaner
Pour it in last thing at night, after the final use of that sink. The enzymes need hours of contact with no water running through to digest the film the brush could not reach.
Leave it overnight
Do not run the tap until morning. An enzyme cleaner flushed away after ten minutes has done almost nothing.
Repeat weekly for three weeks
One treatment removes some of the film. The repeat applications matter more than the strength of any single dose, because you are outlasting the eggs already laid.
Why an enzyme cleaner rather than something stronger? Because the target is organic matter, and enzymes digest organic matter. UC IPM says it directly: regular use of an enzymatic drain cleaner may help prevent the organic buildup. Penn State similarly points to products containing bacteria or enzymes that break down the gelatinous scum in drains.
That’s a pest-control authority and a university extension service recommending the approach, not a cleaning brand. If you want the detail on which enzymes do what, see our explainer on proteases, lipases, and amylases. For the full treatment schedule, we have a dedicated 7-day enzyme drain cleaner plan for drain flies.
💡 Treat Every Drain in the Room
Drain flies move between nearby drains. If you treat only the sink, the ones breeding in the shower or floor drain will simply move back. Treat every drain in the room on the same night, including the tub overflow and any floor drain.
Do drain fly traps work?
Traps work for diagnosis. They don’t work as a cure, and the distinction matters because traps are what most people buy first.
What a trap does well: it tells you which drain is the source. Adults emerge from the drain they were laid in, so a trap over a specific drain that fills up overnight has answered your question. The clear-tape method above is a free version of the same test.
What a trap can’t do: reach the eggs and larvae. Those are inside the pipe, on the wall, in the film. A sticky trap on the counter has no path to them. You will catch adults forever while the population replenishes itself underneath.
Use a trap for the first night to locate the problem. Then put your effort into the drain the trap identified.
How do you find which drain they’re breeding in?
The tape test, and it costs nothing.
- Cover each suspect drain with clear packing tape, sticky side down, leaving a small gap so air can pass.
- Leave it overnight, ideally two or three nights in a row.
- Check each morning. Emerging adults get stuck to the underside.
- Treat the drain that catches flies. If several catch flies, treat all of them.
Don’t skip the drains you never think about. Common culprits:
- Basement and utility room floor drains
- A guest bathroom shower used a few times a year
- The overflow opening on a tub or sink, which has its own film
- Garbage disposals, under the splash guard
- A condensate drain from an air conditioner or dehumidifier
- Sump pits
How long does it take?
Expect one to three weeks, and expect to keep seeing flies during the first week even though the treatment is working.
The reason is the life cycle. UC IPM puts development from egg to adult at as little as 8 days and as long as 24 days depending on temperature. Every adult you see this week was laid before you started. You can’t treat your way out of eggs that already exist, you can only stop new ones from having somewhere to grow.
If you still see fresh flies after three weeks of weekly treatment, you have missed a drain. Run the tape test again and widen the search. Persistent infestations sometimes trace to a broken pipe under a slab or a dry floor drain trap, which is a plumbing problem rather than a cleaning problem.
⚠️ When It Is Not the Drains
If you have treated every drain thoroughly and flies keep appearing, stop treating and start looking. A cracked sewer line, a leaking pipe inside a wall, or a floor drain whose trap has dried out can all breed drain flies. Those need a plumber, not a cleaner.
How do you keep them from coming back?
Film starts rebuilding the day you finish removing it. Prevention is just not letting it get thick enough to breed in.
- Monthly enzyme treatment on every drain in the house, overnight. This is the single highest-value habit.
- Run rarely used drains for 30 seconds every week or two. It keeps traps full and washes down fresh residue.
- Keep food out of the sink. Scrape plates into the trash. Grease is what the film is largely made of.
- Clean the disposal splash guard, which is a breeding site people almost never check.
- Fix slow drains promptly. A slow drain means the film is already thick.
For the routine version of this, our guide to enzyme cleaners for shower and bathroom drains covers the monthly schedule, and how long enzyme cleaners take to work covers what to expect on the timeline.
Wrapping up
Drain flies are a housekeeping problem in your pipes, not a pest problem in your house. The adults are almost irrelevant. Everything depends on whether the film they breed in is still there.
Scrub the pipe walls, apply an enzyme drain cleaner overnight, repeat weekly for three weeks, and keep a monthly treatment going afterward. Skip the bleach. It has never been the answer to this one, and the entomologists who study these flies have been saying so for years.
Frequently Asked Questions
Does bleach kill drain flies?
Are drain gnats and drain flies the same thing?
Do drain fly traps work?
Does Drano kill drain flies?
How long does it take to get rid of drain flies?
Why do I have drain flies if my drains look clean?
Sources
The references used on this page. We link primary sources so you can check our work.
- Moth or Drain Flies, Pest Notes 74167. UC Statewide IPM Program, University of California (ipm.ucanr.edu)
- Moth Flies in the Home. Penn State Extension (extension.psu.edu)
- Drain Flies in the Home: Identification and Management. Alabama Cooperative Extension System (aces.edu)
Related Articles

Enzyme Drain Cleaner for Drain Flies (7-Day Fix)
Drain flies breed in pipe biofilm that chemical cleaners can't remove. Enzyme drain cleaners dissolve it. Follow our 7-day treatment plan.

Enzyme Cleaner for Shower Drains: Clear Hair Clogs
Hair clogs are protein-based, so protease enzymes break them down. Follow our method to clear and prevent shower drain clogs without damaging pipes.

How to Clean a Garbage Disposal With Enzyme Cleaner
Food biofilm causes that garbage disposal smell. Use enzyme cleaner to dissolve it without damaging your disposal or pipes. Follow our weekly plan.
Cleaning Product Researcher
Sarah Chen is a pen name for our lead product researcher. A lifelong dog person who now shares her home with two cats, she's no stranger to enzyme cleaners. She writes the guides and reviews on this site based on product research, ingredient analysis, and real user feedback.