Fungus gnats live in the top inch of your potting mix, and that is the entire diagnosis: the flies you swat at the rim are adults, but the colony is a layer of larvae feeding on fungi and fine roots in the wettest part of the pot. Letting that top inch dry out between waterings, and moving water to the bottom of the pot so the surface stays dry while the root zone still gets hydrated, is what actually breaks the cycle. If the mix stays soggy and the container doesn't drain, they come back no matter what you spray.
Pick up one of your pots right now and do what I do. Tip it toward the window, put your palm across the rim, and look at the surface instead of the plant. What you're looking for is the color of the mix between the stems. Dark, coffee-ground dark, all the way across, days after you watered — that's the layer. That's where the females are laying, singly, in the seams and cracks, and where the larvae are working through the fungus that grows on wet peat and bark.
I stopped counting flies years ago. I count days.
The layer, not the plant
Here's the reframe that changed how I handle these. A pot is not one environment. It's at least two. There's the top inch or so, which is exposed to room air, sits above most of the root mass, and is the only part of the mix that can dry out fast. And there's the root zone below, which stays damp for a long time after the surface goes dry.
Fungus gnat larvae live in the first one. Almost every adult you see came out of that shallow band. So the question is never "how do I kill the gnats," it's "why is that band staying wet long enough for a generation to finish?" At ordinary room temperature a generation runs a few weeks, faster when it's warm and the mix is sodden. That's a long window. You are not fighting an infestation, you are running a wet-surface incubator and wondering why it produces flies.
When I finally understood that, my whole approach collapsed into something much simpler and much more boring. I stopped buying things and started changing the surface.
What drying the top inch actually means
Push a fingertip in at the edge of the pot, not next to the stem where the mix compacts. Down to the first knuckle. If it's cool and clumped and sticks to your skin, that layer is still live, and watering now just extends the lease.
What I trust more than my finger is weight. Lift the pot before and after watering a few times and your hand learns the difference fast — the difference between watered-heavy and ready-heavy. With a plastic nursery pot you can feel it. With a heavy ceramic pot you can't, so use the finger.
The honest tradeoff: some plants do not want their surface dry. A fern, a calathea, a freshly stuck tray of cuttings under a dome — those are exactly the plants that get gnats, because you can't let them dry. This is where the reframe has to get more precise. For those, you don't dry the surface, you decouple it. You water from below and keep the topdressing grit dry, and you accept that you're managing the population rather than eliminating it. For everything else — pothos, philodendron, most of what people actually keep — drying that top inch costs the plant nothing.
Bottom watering, and where it fails
Set the pot in a tray of water an inch or so deep and leave it. Twenty to forty-five minutes for a six-inch pot, longer for a big one. Then lift it out and let it drain somewhere else, not back into the same standing water. Capillary action pulls moisture up into the root zone while the surface stays dry to the touch.
Three places this goes wrong, all of which I've hit.
A mix that has gone bone dry and crusted becomes hydrophobic and won't wick at all. You'll check the weight and it hasn't changed. That pot needs one top watering to re-wet, and then you can go back to bottom watering.
A pot with no drainage holes isn't a pot, it's a vase. Bottom watering in a cachepot without holes just means the base of the root ball sits in a puddle. If the decorative pot has no hole, take the nursery pot out, water it, let it drain, put it back.
And bottom watering doesn't flush anything. Salts and fertilizer residue accumulate because nothing is running out the bottom. Once every month or two I run a full top watering through and let it drain hard, and I plan for a small flush of adults afterward and don't panic about it.
Topdressing is a barrier, not a cure
A half inch of coarse sand or fine gravel over the surface does reduce egg-laying, and I use it. But I want to be blunt about what it does, because I wasted a season believing otherwise: it stops the next generation from getting in. It does nothing to the larvae already down there. If you topdress a pot that's already colonized, you've put a lid on a pot that's still cooking, and the adults will emerge from the drainage holes or from any spot where the grit thins. Topdress after you've dried the layer out, not as a substitute for it. And keep the grit actually dry — if you keep top watering through it, it's just wet gravel, and wet gravel is a fine place to lay eggs.
Sticky cards tell you whether it's working
Yellow cards stuck at the rim, low, near the surface, are a gauge. Nothing more. Catching adults does not touch the larvae, and a card can't keep up with a real population anyway. What it can do is give you a number. Count once a week. If the count drops steadily, the drying is working and you keep going. If it plateaus or climbs, the surface is still wet somewhere — usually under the rim, or in one pot you've been babying.
That's the whole use. It's a thermometer, not a treatment.
The parts nobody wants to hear
The mix and the container are half the problem, and they're the half that makes it recur.
A mix that holds water for ten days in a six-inch pot is telling you something. Either it's too fine and too decomposed, or the pot is too big for the root ball. A pot that's mostly mix and very little root is a reservoir with no pump — nothing is drinking the water, so the top inch never dries, so you get gnats on a plant that looks perfectly healthy otherwise. Sizing the pot to the roots instead of to the shelf aesthetic solves a surprising number of these.
And check the bag. Mix stored damp in a warm room, or a bag opened and resealed with condensation on the inside, is a plausible starting point. I'm not going to tell you a fresh bag is always infested, because I don't know that and neither does anyone else writing confidently about it. But if a plant that was clean gets gnats two weeks after a repot, look at what you repotted it into.
The thing that keeps surprising me is how fast it turns around. Not because anything died, but because you stopped feeding it. Once the top inch dries between waterings and the water comes from below, the larvae have nowhere to finish, the adults have nothing to lay in, and the whole thing winds down on its own schedule over a few weeks. You don't win a war. You just stop running the incubator, and the flies go find somewhere else to be.