‹ All guides

How to Get Rid of Fungus Gnats in Houseplants for Good

A man in a denim shirt bottom-waters a potted plant in a saucer on a windowsill, with a yellow sticky card on a stake in the pot

Illustration: a houseplant soaking up water from a saucer on the windowsill, with a yellow sticky card staked in the pot.

Fungus gnats in your houseplants breed in wet potting soil, so the fix is to starve the larvae: let the top 1 to 2 inches of potting mix dry between waterings, catch adults on yellow sticky cards, and water in Bti every 5 to 7 days. Expect three to four weeks. You’re done when new sticky cards stay clean.

Cost: about $25 in supplies. Time: about 3–4 weeks. Difficulty: moderate. Call a pro if gnats keep coming with no plants in the house and you can’t find the wet spot, such as a leak inside a wall or under the floor.

This guide covers fungus gnats in houseplants, plus the rarer case of gnats in a house with no plants. It won’t promise a one-spray fix: nothing you spray on adults reaches the larvae in the soil, and pupae already there will keep hatching for about two weeks whatever you do.

Saw fungus gnats tonight? Empty the water from every saucer, skip the next watering and press a slice of raw potato onto the worst pot to find the larvae. Add yellow sticky cards as soon as you can buy them. Don’t spray the air; it won’t reach the larvae in the soil.

What Works and What Doesn’t Against Fungus Gnats

MethodWorks?CostMain limitation
Letting the top 1–2 inches of soil dryYes, does most of the workFreeSome plants can’t take dry soil
Yellow sticky cardsPartly: catches adults, shows progress$4.97 for 12Never ends it while larvae grow underneath
Bti drench every 5–7 daysYes, kills larvae$19.98 a bagDoesn’t touch eggs, pupae or adults
Beneficial nematodesYes, per UC IPM—Live and perishable; best for big collections
Hydrogen peroxide drenchPartly: kills larvae it touches$0.99A sanitizer; skip seedlings
Cinnamon, vinegar traps, air spraysNo—Miss the larvae in the soil

Fungus Gnats or Fruit Flies?

Flies rising from potting mix are almost always fungus gnats, even if you searched how to get rid of fruit flies in house plants; skip to Step 1. Otherwise, “gnat” covers three small flies with different fixes (full sorting: how to get rid of gnats):

  • Fungus gnats: dark, 1/16 to 1/8 inch, like tiny mosquitoes. Weak fliers that stay near pots, walk on the soil or rest on windows.
  • Fruit flies: tan, usually red-eyed, around overripe fruit. They need a fruit fly plan that starts with the fruit bowl.
  • Drain flies: fuzzy, around sinks and floor drains. Getting rid of drain flies means cleaning the slime inside the drain.

Are Fungus Gnats Harmful?

Not to people. Adult fungus gnats don’t bite or damage plants; UC IPM calls them primarily a nuisance.

The larvae can chew roots and, in large numbers, stunt seedlings and young plants. Serious damage is rare in homes; a wilting houseplant more often has a watering or root-rot problem.

Step 1: Find Which Plants Have Fungus Gnats

Most of a fungus gnat’s life is spent in the soil. The adults you see live about a week, so killing them alone never ends it. Find which pots hold the larvae:

  • Potato slice test. Press a ¼-inch slice of raw potato onto the soil. Within a few days, flip it and look for tiny clear worms with black heads (Colorado State University Extension).
  • Sticky card per pot. A yellow card in each pot shows which plants catch the most adults.
  • Cloth test, if you also have drains. Drape cheesecloth or window screen over one suspect pot, or over the drain, and check it over the next few days. Flies showing up under the cloth tell you that’s the source.

Don’t move infested plants next to clean ones, where adults can reach more pots.

Two panels: a slice of raw potato pressed onto potting soil, and the slice flipped over to show a few tiny pale larvae with black heads

Illustration: a potato slice on the soil (left), and the same slice turned over to show a few tiny larvae on its underside (right).

Step 2: Let the Soil Dry Out

This step does most of the work. When the soil dries, the larvae die and females stop laying eggs there.

  • Water less often. Let the top 1 to 2 inches dry before watering again. Check with a finger.
  • Water from the bottom. Set the pot in a saucer of water and let the roots drink, so the surface stays dry.
  • Empty saucers and fix any pots that don’t drain.
  • Cut back in fall and winter. Plants use less water then, which is one reason fungus gnats peak in late fall and winter.

Some plants can’t take dry soil even with bottom-watering, Cornell Cooperative Extension notes. For those, lean on the sticky cards and Bti below instead.

Step 3: Trap Adults With Yellow Sticky Cards

Adults are drawn to yellow. Cut cards into small squares on stakes and set them just above the soil. They catch egg-laying females and show whether numbers are falling. Replace a card when it’s covered.

  • Pets or toddlers? The glue grabs fur and fingers, so use small squares tucked low under the leaves and move pots a cat or child can reach up out of the way.
  • Cards alone won’t finish it while larvae keep growing underneath. One Reddit poster ran 50 sticky traps across their plants and was still fighting a month later.

Step 4: Kill the Larvae With Bti

Bti comes as the mosquito granules sold for birdbaths and ponds, such as Mosquito Bits, in garden centers. It’s a bacterium whose toxin affects only the larvae of mosquitoes, black flies and fungus gnats.

  1. Buy the right kind. The label must say israelensis. Bt sold for caterpillars doesn’t work on fly larvae (UC IPM).
  2. Make the tea. The fungus gnat directions on the label: 4 tablespoons of granules per gallon of water, soak 30 minutes, skim off the floating granules (or soak them in a nylon stocking), stir, then pour onto the soil.
  3. Use it as a normal watering. Water with the tea only once the top inch or two has dried, so it doesn’t undo Step 2.
  4. Repeat every 5 to 7 days for about three weeks. Bti doesn’t last in potting mix and doesn’t touch eggs, pupae or adults, so each dose catches new larvae. Expect adults for about two more weeks.

Safe with kids and pets? The EPA says Bti has no toxicity to people, and mammals lack the gut enzymes and receptors that activate its toxin. A cat lapping saucer water isn’t the worry a chemical spray would be.

Other Biological Options: Beneficial Nematodes

UC IPM lists Steinernema feltiae nematodes as another biological control, and the most effective nematode species against fungus gnats. They’re microscopic worms you mail-order, mix with water and drench into the soil right away, since they’re live and perishable. They work in moist soil between 60° and 90°F and, after a few applications, can keep reproducing for longer-term control. For a few houseplants, Bti is cheaper and easier; nematodes make more sense for a large indoor collection. UC IPM says predatory mites, the other option, probably aren’t a good choice for single houseplants.

Light infestation? Drier watering plus a sand or gravel top layer (Step 5) can get gnats in check in three to four weeks without Bti, says Wisconsin Horticulture.

Two panels: gloved hands stir small granules into a jar of water, then pour the strained liquid from a watering can onto a potted plant's soil

Illustration: granules steeping in a jar of water (left), then the liquid watered into a pot until it drains into the saucer (right).

Step 5: Repot or Toss the Worst Plants

Old potting mix breaks down and holds more water. Repot badly infested plants into fresh bagged potting mix; UC IPM advises buying pasteurized mix, meaning heat- or steam-treated so no gnats ride in. Keep open bags closed and off the floor. A plant past saving can go in the trash.

A ½- to 1-inch layer of coarse sand or fine gravel on top keeps the surface dry and less attractive for egg-laying (Wisconsin Horticulture).

Hydrogen Peroxide, Cinnamon and Other Home Remedies

  • Hydrogen peroxide: a cheap first try that kills larvae it touches. Mix 1 part 3% hydrogen peroxide with 4 parts water and pour it over the soil; it fizzes as it hits the larvae, which is normal (Cornell Cooperative Extension). It’s also a sanitizer, so one extension expert said to use it cautiously, skip seedlings and try drier soil and Bti first. Let the soil dry afterward.
  • Cinnamon: doesn’t work. A UC IPM myth-busting post says “potato chunks and cinnamon won’t relieve you of fungus gnats.”
  • Apple cider vinegar traps: fine for fruit flies, but Wisconsin Horticulture says they don’t work for fungus gnats.
  • Neem oil, soap and pyrethrin sprays: need reapplying every few days, hit only adults and miss the larvae. If you spray anyway, use a houseplant-labeled product on the soil surface, never the air.

Fungus Gnats in House With No Plants

No plants? Fungus gnat larvae live in any moist organic material. Look for:

  • Drains with a buildup of moist debris. Clean out the trap.
  • Leaks and standing water, such as a slow drip under a sink.
  • Bags of potting soil, compost or organic fertilizer stored indoors.
  • Inside walls, rarely, where moisture is high enough for fungus to grow.

Also check they’re fungus gnats at all: flies at drains are often drain flies. Tiny specks that jump in the soil rather than fly are likely springtails, which also mean wet soil and need drying out, not spraying.

Why Do Fungus Gnats Keep Coming Back?

One Reddit poster wrote “I have tried all the things and they will not go away” after months of Bti, neem and sticky traps. Usually it’s timing or one missed source:

  • Pupae keep hatching. A new generation takes about 17 days at 75°F (UC IPM), and Bti doesn’t touch pupae. Adults for two weeks after you start are normal.
  • One pot is still wet. Pots without drainage holes, self-watering pots and full saucers keep a colony going.
  • New plants or soil bring more, such as a plant brought in from outdoors.
  • The source isn’t a plant. Check drains and leaks.

How Long Does It Take to Get Rid of Fungus Gnats?

Three to four weeks. At 75°F, fungus gnat eggs hatch in about 3 days, larvae feed for about 10 days, and adults emerge about 4 days later, so a full generation takes about 17 days (UC IPM). Bti and dry soil kill larvae, but pupae already in the soil still hatch, so expect adults for the first two weeks. Keep going until fresh sticky cards stay clean for a week or two.

Which Plan Fits Your Situation

Your situationStart withThen
A few gnats, one or two plantsDrier watering and a sand or gravel top layerSticky cards to confirm they’re gone
Gnats in many potsPotato or sticky-card test per potBti every 5–7 days for three weeks
A plant that must stay moistSticky cards and BtiBottom-watering only
A large indoor collectionBti or Steinernema feltiae nematodesA pro if it outgrows a watering can
Flies but no plantsDrains, leaks and stored potting soilCheck they aren’t drain flies
Tiny specks that jump, not flyProbably springtailsDry out the soil the same way

What It Might Still Cost

ItemTypical cost
Yellow sticky traps for plants, 12-pack$4.97
Bti granules, 8 oz bag$19.98
DIY kit: sticky traps and BtiAbout $25
3% hydrogen peroxide, 32 oz (optional)$0.99
Pro fungus gnat treatment$100–$150

DIY: Walmart and Target list prices, October 1, 2026, before tax. Pro: Fixr (updated January 2025), which says fungus gnats can’t be controlled with chemical treatments because that would likely kill the plants.

Before You Start: A Quick Checklist

  • Empty every saucer and cachepot tonight.
  • Test the worst pots with a potato slice or a sticky card each.
  • Check the label says israelensis before you buy Bti.
  • Set a reminder to drench every 5 to 7 days for three weeks.
  • Stake small sticky squares low, out of reach of pets and kids.
  • Keep open bags of potting mix sealed and off the floor.
  • Look at drains and under sinks if some flies aren’t near plants.

When to Call a Pro

  • You have no plants and can’t find the wet spot. A leak inside a wall or under a floor is a plumber’s job.
  • A large indoor collection, such as an office or plant shop, outgrows a watering can.
  • Nothing has worked after six weeks of dry soil, sticky cards and Bti. Ask what the pro will do about larvae in the soil, not just what they’ll spray. Our guide to what an exterminator does covers what to ask before you sign.

Common questions

Yes. That’s why you often first notice them at windows and lamps. A light trap only catches adults; the source is still the soil.

The Bottom Line

Fungus gnats are a watering problem more than a bug problem. Dry the top of the soil, water in Bti every 5 to 7 days for about three weeks and let sticky cards tell you when you’re done. Expect adults for the first two weeks. If flies keep coming with no wet pot in sight, look for a leak, and if they turn out to be a different small fly, start from how to get rid of gnats.

Sources and further reading · 8

Get new guides and updates

We'll email you when we publish a new guide. No spam. To sign up, send a quick note to the address below.

[email protected]