How to get rid of fungus gnats
Written by Mustafa Ayan Fact-checked against university extension/IPM sources Last reviewed: September 19, 2026
Direct answer
Get rid of fungus gnats in this order: confirm it's actually fungus gnats (not fruit or drain flies), find the likely breeding source (a consistently damp nearby pot is a common culprit, but check other damp organic sites too, such as drains), adjust watering so the mix dries out appropriately for that specific plant, set yellow sticky traps at soil level to monitor and catch adults, and — if moisture control and traps aren't enough on their own — use a Bti product labeled for fungus gnats, following the current label's rate and reapplication schedule. You may see fewer adults within days, but complete control often takes several weeks, since eggs and larvae already in the soil keep developing on their own timeline regardless of when you start treating. Keep monitoring trap catches after adult numbers fall rather than stopping the moment things look clear.
Get the day-by-day planWhy fungus gnats appear
Fungus gnats don't come from nowhere — most cases trace back to moisture and organic matter, commonly in potting mix, though other damp organic sites are possible too. The full breakdown is in our causes guide, but the short version:
- Soil that never fully dries. This is the single biggest driver. Overwatering, poor drainage, or a moisture-retentive mix (heavy on peat) keeps the top inch of soil damp enough for eggs to survive and larvae to feed, week after week.
- Organic matter breaking down in the mix. Larvae feed on fungi and decaying organic material — bark, peat, and root debris in ordinary potting mix. Compost-heavy or well-used mix gives them more to eat and a more established fungal food source.
- New plants or bagged soil brought in already infested. Fungus gnats hitchhike in nursery pots and in bagged potting mix that was stored somewhere damp. A new plant is a common, easy-to-miss entry point.
- Standing water in saucers or cachepots. A saucer that holds water after every watering, or a decorative cachepot with no drainage, keeps the base of the pot wet even when the surface looks dry — a second nursery you can't see.
How to identify fungus gnats
Fungus gnats are slender, dark, mosquito-like flies with long legs and weak flight — they hover near soil and lift off when you water, rather than darting toward fruit or drains. If you're not certain, use the interactive identifier or read the full fungus gnats vs. fruit flies comparison. Treating the wrong pest is the single most common reason people think a method "didn't work."
The fungus gnat life cycle
You're fighting a life cycle, not a batch of flies. Indoors, egg to adult takes roughly three to four weeks, and every stage after the egg overlaps with the next — which is why a single treatment rarely finishes the job. Full detail, including how to interrupt each stage, is in the life cycle guide.
Step-by-step elimination process
- 1
Confirm the pest
Rule out fruit flies and drain flies first — see the identifier or the comparison guide. Treating the wrong pest is the most common reason a plan seems to fail.
- 2
Find the likely breeding source
A consistently damp nearby pot is a common culprit, but don't assume — check every nearby pot's soil moisture, any saucer or cachepot holding water, whether a recently acquired plant or bag of mix is involved, and whether a drain with damp debris is actually the source instead. Treating a spot that isn't actually the source wastes effort and delays real progress.
- 3
Manage moisture for that specific plant
Most houseplants do well letting the top 1–2 inches dry between waterings, but that's not a universal rule — a succulent, a seedling, and an orchid in bark each tolerate moisture differently. Allow the growing medium to dry as far as the plant safely tolerates — see what fits your plant in the drying guide.
- 4
Set yellow sticky traps at soil level
One card per small pot, two for a large planter, pushed into the mix so the yellow face sits just above the soil. Traps monitor and capture adults — they don't touch eggs or larvae in the soil.
- 5
Add a labeled Bti product if suitable
Bti (sold as Mosquito Bits or Gnatrol) targets fly larvae in the soil. Use a product labeled for the intended application and follow the current label for the exact amount, preparation method, application site, and retreatment interval — directions vary by product and jurisdiction.
- 6
Monitor the trend and continue accordingly
Watch the trend on your sticky cards over days, not a single count. Continue moisture management and any labeled treatment according to the label and what you're observing, long enough to account for remaining immature stages, rather than stopping on a fixed schedule.
- 7
Troubleshoot if activity doesn't decline
A flat or rising trend after a reasonable stretch of consistent treatment usually means the source wasn't fully addressed, not that the method failed. The troubleshooting self-check walks through the common reasons.
Suggested YouTube video
See the process, not just read it
If you'd rather watch the dry-soil-plus-larvae approach in action, this is a clear walkthrough of the same core method described above.
Watch on YouTube
Every treatment option, compared
Each method targets a different stage of the life cycle. Full instructions for each are one tap away — see the treatments hub.
| Method | Targets | Time |
|---|---|---|
| Let the soil dry | Eggs and larvae | Ongoing |
| Yellow sticky traps | Flying adults | 5 minutes |
| Bti (Mosquito Bits) | Larvae | Per product label |
| Hydrogen peroxide drench | Larvae | 10 minutes |
| Prevention that actually sticks | The next generation | Habit change |
Natural methods, honestly rated
Search results for fungus gnats are full of home remedies. Some hold up; others are repeated because they're cheap and easy, not because they work well. Here's the distinction — full detail in the natural control guide.
- Letting the soil surface dry between waterings well-supported
Removes the moisture eggs and larvae need to survive. Extension sources consistently list this as the foundation of control — not a supplement to it.
- Bti (Bacillus thuringiensis israelensis) well-supported
A naturally occurring soil bacterium sold as Mosquito Bits or Gnatrol. It targets fly larvae specifically and is used in organic growing operations. A drench is itself a watering event — apply it in place of a scheduled watering, not on top of one, so you're not undoing the dry-soil habit while treating larvae.
- Beneficial nematodes (Steinernema feltiae) well-supported
A microscopic parasitic worm that actively hunts fungus gnat larvae in the soil. Needs consistently moist, temperature-appropriate soil to survive and work. They're a live product with a short shelf life — buy from a supplier that ships them cold, apply promptly, and expect a higher cost per treatment and less retail availability than Bti.
- Yellow sticky traps well-supported
Well-supported specifically for monitoring and knocking down egg-laying adults — that's the claim, not elimination. On their own, traps don't touch eggs or larvae already in the soil, so a clean-looking card doesn't mean the pot is clear.
- Sand or grit top-dressing limited evidence
A dry, mineral surface layer is a plausible deterrent to egg-laying and helps the very top of the mix dry faster, but it's a supplementary, preventive step, not a documented larvicide — use it after larvae numbers are already down, not as a first-line treatment.
How long elimination takes
You may see fewer adults within days of managing moisture and trapping, but complete control often takes several weeks — a light infestation on one or two plants may settle within a week or two, while a heavier, multi-plant infestation commonly takes closer to a month, because eggs and larvae already in the soil keep completing their development even after treatment starts. These ranges are approximate and vary with temperature and how consistently moisture is managed. See troubleshooting below if progress stalls rather than just slows.
Keeping them from coming back
Prevention is the same dry-soil habit that got rid of them, kept up after the infestation looks over. Bottom-water where you can, top-dress with sand or grit once larvae are down, use a well-draining mix, and give new plants a week of quarantine with their own sticky card before they join the rest of the collection. Full walkthrough: prevention that actually sticks.
Common mistakes
- Treating only the adults. Sprays and traps knock down what's flying, but the soil keeps producing more. Larvae are the part of the population doing the real damage to a treatment plan.
- Stopping as soon as the flies disappear. Eggs and pupae already in the soil can still finish developing after adults stop appearing. Keep monitoring after adult numbers fall, and continue moisture management and any labeled treatment long enough to account for those remaining stages — don't stop the moment the air looks clear.
- Watering "just to be safe". A single deep watering out of habit can rewet a drying pot and hand the next generation exactly what it needs. Check the soil, don't guess on a schedule.
- Missing a second infested pot. Gnats move freely between nearby plants. Treating one pot while a neighboring one stays wet just gives the population a place to wait you out.
Troubleshooting
More scenarios in the full troubleshooting guide.
Why do fungus gnats keep coming back after I've treated them?
Almost always one of three things: the soil surface is still staying damp between waterings, larvae already pupating when you treated have finished emerging as adults, or a second pot nearby is still infested and reseeding the room. Treat every pot in the area at once. Keep monitoring after adult numbers fall, and continue moisture management and any labeled treatment long enough to account for remaining immature stages still developing in the soil — not just until things look better.
Why aren't my sticky traps working?
Sticky traps only catch flying adults — they do nothing to eggs or larvae in the soil, which is where most of the population actually lives at any given time. A trap that stays clean can also mean the card isn't at soil level, is dusty or full, or is simply overwhelmed by egg-laying happening faster than adults are trapped. Traps are a monitoring and knock-down tool, not a standalone fix.
How long should full elimination realistically take?
You may see fewer adults within days once the mix stays dry and adults are being trapped, but complete control often takes several weeks — longer for a heavier, multi-plant infestation — because eggs and larvae already in the soil keep completing their life cycle even after you start treating. These timelines are approximate and depend on temperature and consistency of treatment; don't assume a method has failed before giving it that full window.
FAQ
Q01 How do I know if I have fungus gnats?
They are tiny dark flies that look like mosquitoes, with long legs. They hover around houseplant soil and often fly up when you water. Fruit flies hang around kitchens and produce. Drain flies look fuzzy and sit on bathroom or kitchen drains.
Q02 Do fungus gnats bite people?
No. Adults are a nuisance in the air and on windows. The damage is underground: larvae feed on fungi, organic matter, and sometimes fine roots — especially on seedlings.
Q03 How long does it take to get rid of fungus gnats?
You may see fewer adults within days once moisture is managed and adults are being trapped, but complete control often takes several weeks, longer for a heavier infestation, because eggs and larvae keep hatching on their own schedule. Keep monitoring after adult numbers fall — don't assume it's over the moment things look clear.
Q04 Will cinnamon or vinegar traps be enough?
Vinegar traps catch some adults but are built for fruit flies. Cinnamon is a mild fungicide and may help a little. Neither replaces dry soil plus a larval treatment. Use them as extras, not the plan.
Q05 Are fungus gnats dangerous to plants?
Mature plants usually tolerate a few larvae. Heavy numbers can slow growth, yellow leaves, and damage seedlings. The bigger problem for most people is the cloud of flies in the room.
Q06 Can I just repot?
Repotting into fresh, well-draining mix helps if the old mix is compacted and constantly wet. Rinse as much old mix off as the plant will allow, and still use traps plus a drier watering schedule. Repotting alone often leaves eggs on the bench and in nearby pots.
Q07 Are Bti and hydrogen peroxide safe around pets and kids?
Bti (Mosquito Bits/Gnatrol) is targeted at fly larvae and is widely used in organic growing, generally considered low-risk when used as labeled; hydrogen peroxide at the diluted, household-strength concentrations some sources describe is also generally considered low-risk, but this site treats it as an optional, cautious add-on rather than a default step. Sticky traps are genuinely hazardous to curious pets (they can stick to fur or be swallowed) — keep cards out of reach of paws and hands. Always follow the current product label for any packaged pesticide, since directions can differ by product and jurisdiction.
Q08 Do fungus gnats spread from one plant to another?
Yes. Adults are weak fliers but wander freely between nearby pots, and a female can lay eggs in any moist mix she finds — including a neighboring plant that was never infested to begin with. This is why treating only the pot you first noticed gnats in often fails: check and treat every plant in the same room or shelf, not just the source.
Q09 Will a store-bought fogger or spray get rid of them?
Adult sprays may reduce the flies you see temporarily, but they do not address eggs, larvae, or pupae developing in the growing medium. For a houseplant infestation, focus first on finding the source, managing moisture appropriately, monitoring adults, and using an appropriate labeled larval treatment when needed. Foggers and contact sprays aren't part of the standard workflow here — that's not a claim that every such product is unsafe or ineffective, just that they don't reach the stage actually driving the infestation.
Q10 What about succulents, cacti, or orchids specifically?
Fungus gnats are far less common in these because their mix is already fast-draining and watered infrequently. If you do see them, the usual cause is a mix or pot holding more moisture than that plant needs — fixing drainage matters more than adding a liquid drench, since repeated moisture is a bigger risk to a succulent than to a moisture-tolerant tropical. See the drying guide's note on succulents and orchid bark for specifics.
Sources
Factual claims about biology and treatment mechanisms on this page are checked against university extension and public-health sources, including:
- Fungus Gnats — Pest Notes — UC Statewide IPM Program (UC IPM)
- How to treat pesky fungus gnats in houseplants — University of Minnesota Extension
- Bacillus thuringiensis (Bt) Fact Sheet — National Pesticide Information Center (NPIC)
- Steinernema feltiae, Beneficial Nematode (Sf) — Cornell University — Integrated Pest Management