How do I get rid of fungus gnats in potting soil?

March 12, 2026 3 min read

Adult fungus gnats lay eggs in moist organic compost, particularly peat-heavy composts that stay wet near the surface. Eggs hatch within a few days into larvae that feed on organic matter and fungal material in the compost, and can also damage fine roots and seedling stems in large numbers. After two to three weeks as larvae, they pupate and emerge as adults, which mate and lay more eggs, completing the cycle in roughly four weeks at typical room temperatures.

The key vulnerability in this cycle is the larval stage: larvae require moist conditions in the top 3 to 5cm of compost to survive. Allowing this layer to dry out between waterings kills larvae before they can complete the cycle. This is the single most effective treatment and costs nothing.

Let the Compost Dry

Reduce your watering frequency until the top 3 to 5cm of compost is consistently dry between waterings. Not just the surface: the compost at a finger's depth should feel dry before you water again. This kills existing larvae and removes the conditions that make the compost attractive for egg-laying adults. For established fungus gnat populations, strict moisture management for three to four weeks is usually sufficient to break the breeding cycle.

Most tropical houseplants tolerate this approach well; it often corrects the overwatering that allowed the gnats to establish in the first place. The main exception is moisture-loving plants like Ferns and Calatheas, which should not be allowed to dry significantly. For these plants, the moisture management approach is less practical, and biological treatment with Bti is the better primary option.

Use Yellow Sticky Traps

Yellow sticky traps placed at or just above the soil surface catch adult gnats as they emerge and move around. They do not eliminate an infestation on their own, the larvae in the soil are unaffected, but they significantly reduce the adult population, break the egg-laying cycle more quickly, and provide an easy way to monitor whether numbers are declining. A reduction in trapped adults over two to three weeks is a reliable sign the treatment is working.

Use Biological Treatments

Bacillus thuringiensis israelensis (Bti) is the most effective targeted treatment for fungus gnat larvae. Available as granules (e.g. Gnat Off, Fungus Gnat Killer) or in liquid form, it is applied as a soil drench that larvae ingest when they feed. It is highly specific to dipteran larvae (gnats and mosquitoes) and has no effect on plants, earthworms, bees, pets, or humans. This makes it an ideal option for households with children or pets.

Apply according to product instructions, typically every two weeks for two to three cycles to ensure full coverage of successive larval generations. Combine with reduced watering for maximum effect.

Use Topdressing

A layer of coarse horticultural grit, sand, or shells applied over the compost surface creates a physical barrier that adult gnats find less attractive for egg-laying and that dries quickly after watering. A 1 to 2 cm layer of grit is sufficient. This is a useful preventive and supplementary treatment rather than a cure for an active infestation, but combined with correct watering it can prevent re-infestation after clearing an existing problem.

What not to use when dealing with Fungus Gnats 

Cinnamon powder is sometimes recommended as a surface treatment, it has some antifungal properties that may reduce the organic material fungus gnats feed on, but it does not kill larvae reliably and should not be relied on as a treatment.

Hydrogen peroxide soil drench (at 1 part 3% H2O2 to 4 parts water) kills larvae on contact but also damages fine roots and beneficial soil biology, It isn't recommended unless an infestation is causing serious root damage and other methods have failed.

Frequently Asked Questions

In small numbers, fungus gnat larvae cause minimal direct harm — they feed primarily on organic matter and fungi rather than healthy roots. In large numbers or in seedling trays, larvae can cause more significant root damage and introduce fungal pathogens. The adult gnats are a nuisance but do not damage plants. A modest infestation in a healthy established plant rarely causes serious harm; the priority is breaking the breeding cycle before numbers build.
Most fungus gnat infestations originate from the compost itself — purchased growing media often contains eggs or larvae from commercial growing environments. They can also fly in through open windows or arrive on new plants. Reducing the amount of time compost bags are left open (seal unused compost in an airtight container) and checking new plant arrivals before quarantine ends helps prevent introduction.
Yes. Predatory nematodes (Steinernema feltiae) are a biological control effective against fungus gnat larvae. They are watered into the compost and actively seek out and parasitise larvae. They are available from UK garden suppliers, work best at soil temperatures above 12°C, and are completely safe for plants and humans. They are slightly less readily available than Bti but equally effective. See our guide on common houseplant pests for context on fungus gnats alongside other pests.