You lean in to water your plant, and a cloud of tiny insects lifts off the soil surface. If you keep houseplants long enough, you'll probably notice small flies hovering around a pot at some point. The plant itself looks fine — but bugs flying around your home are hard to ignore.
The good news: this is a problem with a very clear source and a very clear fix. In this article, I'll cover why these flies appear and how to stop them, starting with the most effective measure of all — changing the surface of the soil.
Which fly is it? Telling fungus gnats from fruit flies
They tend to get lumped together as "tiny flies", but the small flies you see indoors fall into two main groups. Since where you need to act is completely different for each, start by figuring out which one you have.
| Fungus gnats (dark-winged fungus gnats) | Fruit flies | |
|---|---|---|
| Appearance | Dark and slender, like a miniature mosquito | Brownish and rounded, with red eyes |
| Size | About 1–2 mm | About 2–3 mm |
| Where they hang out | The soil surface of your pots, around plants | Around food scraps, fruit, unfinished drinks |
| Flight | Weak, drifting flight | Quick and darting |
If they're hovering around your houseplant and rising off the soil every time you water, they're almost certainly fungus gnats. Their breeding ground is completely separate from the fruit flies drawn to kitchen scraps — so cleaning your trash bin won't reduce fungus gnats, and vice versa.
The two causes behind fungus gnats
Fungus gnat larvae feed on moist organic matter in the soil. In other words, the cause is this combination:
- Organic-rich soil: potting mixes heavy in composted leaf mold and other organic matter are a feast for the larvae. Eggs are laid in the top 2–3 cm (about an inch) of soil, and the larvae develop right there
- Constantly wet soil: when soil stays damp, the organic matter keeps breaking down (rotting) — exactly the environment fungus gnats love. They won't lay eggs in dry soil
Remember it as "organic matter × moisture": when both line up, the gnats show up. If you tend to water frequently, you may be carrying a root rot risk alongside the gnats, so it's worth checking the signs of overwatering as well.
The most effective fix: top the soil with a mineral layer
The single most effective measure is to cover the top 2–3 cm of soil with an inorganic, mineral material.
Fungus gnats lay their eggs near the soil surface, and the larvae develop in that same shallow layer. If the surface is a mineral layer with no organic matter, there's simply nowhere left to lay eggs. Because it cuts off the cause at the root, it's far more reliable than chasing adult gnats around with spray.
Materials that work well
- Akadama (a mineral bonsai soil), small grain: inexpensive, easy to find at garden suppliers, and looks natural. If in doubt, start here
- Decorative sand or gravel: white or black stones that also sharpen up the look of the pot as a bonus
- Kanuma (another mineral soil) or vermiculite — any granular medium free of organic matter works
How to do it
- Remove any fallen or dead leaves from the soil surface
- Scoop off the top 1–2 cm of soil (this removes a good share of the eggs and larvae with it)
- Spread the akadama or gravel in a layer 2–3 cm thick
That's all. Larvae already in the soil will keep emerging as adults for a week or two, but with no new eggs being laid, the population collapses once that generation runs out.
If you have a repotting planned anyway, switching to a low-organic potting mix at that point is another way to fix the problem at its source. The steps are covered in repotting basics.
Three measures that work well alongside it
With the soil topping as your main fix, combining these three helps things settle down faster.
1. Yellow sticky traps to reduce the adults
Fungus gnats are drawn to the color yellow. Stick a yellow sticky trap — sold at garden centers and dollar stores — into the soil, and it will steadily catch the flying adults. Think of it as a supporting measure: fewer adults means fewer eggs.
2. Rethink your watering rhythm
Simply switching to a rhythm of watering only after the soil surface has fully dried makes the pot a poor place to lay eggs. Try making it a habit to touch the surface and hold off if it's damp, or push a wooden skewer into the soil to check. It's a two-for-one adjustment: fungus gnat control and root rot prevention at the same time.
3. Don't let water sit in the saucer
Water left in the saucer keeps the bottom of the pot constantly wet, and it can become a breeding spot in its own right. After watering, empty the saucer every time. Unglamorous, but it genuinely works.
What you don't need to do
- Blasting insecticide spray over and over: it kills the flying adults, but it doesn't reach the eggs and larvae in the soil. With the source untouched, you end up playing whack-a-mole
- Blaming yourself: it's quite common for store-bought potting mix to arrive with eggs already in it. This isn't a sign you've been careless — just calmly change the conditions and you'll be fine
For what it's worth, adult fungus gnats don't chew leaves or suck sap, so their direct harm to the plant is minimal. If you're seeing insects or spots on the leaves themselves, that may be a different problem — see how to identify spider mites, scale, and other pests.
Wrap-up: a dry, mineral surface means no gnats
- The tiny flies around your pots are almost always fungus gnats — a different insect from the fruit flies around food scraps
- The cause is organic soil × excess moisture. Egg-laying and larval growth both happen in the top 2–3 cm of soil
- A mineral topping of akadama or decorative gravel is the most effective fix. Combine it with sticky traps, a watering rethink, and emptying the saucer, and things settle down quickly
At its core, fungus gnat prevention comes down to a rhythm of letting the soil dry properly before watering again. Green Logs is a free tool that takes away the "when did I last water this?" moments and keeps track of the right watering interval for each of your plants. It works right in your browser — a handy companion whenever you want to reset your watering rhythm.