Key takeaways
- Tiny flies around houseplants are usually fungus gnats, which breed in damp compost
- Let the top 3cm of compost dry out between waterings, especially in winter
- Yellow sticky traps catch the adults, but most of the problem is larvae in the compost
- Nematodes watered into the compost are the best way to kill the larvae
- Keep everything going for 6-8 weeks to catch each new generation
Tiny flies hovering around your houseplant pots are a common winter nuisance in UK homes. They’re almost always fungus gnats, though fruit flies, whitefly and shore flies turn up indoors too.
Happily, they’re easy to beat. Drier compost, yellow sticky traps and nematodes clear most problems in 6-8 weeks. Here’s how to work out which fly you have, deal with it, and stop it coming back.
How to identify houseplant flies
Working out which fly you have tells you which treatment will work. Four kinds of small fly turn up around UK houseplants.
Fungus gnats
Fungus gnats are the usual suspects. They’re tiny, dark grey or black, with long legs. They run across the compost in a jerky way and flutter weakly around the plant rather than flying across the room.
Their larvae are tiny, see-through white grubs with shiny black heads, living in the top few centimetres of damp compost. They mostly eat rotting bits and fungi in the compost, but can nibble the roots of seedlings and soft cuttings.
Fruit flies
Fruit flies are tan or brownish with red eyes. They love fermenting fruit, wine and kitchen bins. If your flies hang around the fruit bowl rather than the plant pots, they’re fruit flies, not fungus gnats. They don’t breed in compost.
Whitefly
Whitefly are tiny, white and moth-like. They sit under the leaves and fly up in a little white cloud when you touch the plant. They suck sap and leave sticky honeydew. They’re fond of fuchsias, pelargoniums, poinsettias and tomatoes.
Shore flies
Shore flies are dark, chunkier than fungus gnats, and fly strongly. They’re more common in greenhouses than homes, and feed on the green algae on wet compost.
Which fly is it?
| Fungus gnat | Fruit fly | Whitefly | Shore fly | |
|---|---|---|---|---|
| Looks like | Tiny, dark, long legs | Tan, red eyes | Tiny, white, moth-like | Dark and stocky |
| Where you see it | On the compost | Fruit bowl, bins | Under leaves | Wet, green compost |
| How it flies | Weak, near the soil | Straight, towards light | Flutters up in a cloud | Strong and direct |
| Harms plants? | Larvae nibble young roots | No | Yes, sucks sap | No |
| Breeds in compost? | Yes | No | No | Yes, where there’s algae |
How fungus gnats breed
Knowing how they breed is the key to beating them. Each treatment hits a different stage, and miss one and they bounce back.
Why most people don’t get rid of them
In a warm house, fungus gnats go from egg to adult in about a month, a bit slower in cooler rooms. There are four stages.
Eggs: females lay them on the surface of damp compost. They’re too small to see and hatch within days.
Larvae: these do the damage. They feed in the top few centimetres of compost for a couple of weeks. At any one time, most of the gnats are in the compost as eggs, larvae and pupae, not flying around.
Pupae: the larvae turn into pupae near the surface. Traps don’t touch them.
Adults: these come out, mate and lay more eggs within days. They live about a week and don’t harm plants.
The big mistake: people see dead flies on a sticky trap, think the job’s done and stop. But the larvae and pupae are still in the compost. A couple of weeks later, a fresh wave of adults appears. Keep all your treatments going for at least 6-8 weeks to catch every generation.
Why autumn and winter are worst
Fungus gnats breed all year indoors, but you notice them most from October to March. Plants that summered outside come back in, sometimes with eggs in the compost. Central heating keeps them breeding. And plants need less water in winter, but many of us keep watering as if it’s summer. That damp compost is just what the gnats want.
Will fungus gnats go away on their own?
Not while the compost stays wet. Indoors there’s no cold winter to stop them, so each generation just replaces the last. Let the compost dry out more, if the plant can take it, and numbers soon drop.
Treatments compared
The flies you see are only a small part of the problem. Most of it is in the compost, so anything that only kills adults won’t work on its own.
| Treatment | What it hits | How well it works | What it’s for |
|---|---|---|---|
| Drier compost | Eggs and young larvae | Very well, if the plant can take it | The starting point |
| Nematodes | Larvae | Very well | The main treatment |
| Repotting into fresh compost | Eggs, larvae and pupae | Very well for that pot | Bad infestations |
| Predatory mites or beetles | Eggs, larvae and pupae | Well, but slower | Keeping them down |
| Grit on top of the compost | Stops egg-laying | Fairly well | A barrier |
| Yellow sticky traps | Adults only | Not much on their own | Spotting and catching adults |
Yellow sticky traps
Yellow sticky traps quickly cut adult numbers, but they only deal with a small part of the problem. Think of them as a helper, not a cure.
Adult gnats are drawn to yellow. Push a trap into the compost so the sticky part sits just above the soil, one for every two or three plants. They’re cheap from garden centres and start catching flies within a day or two.
Traps alone will never fix it. Use them with nematodes or predatory mites to deal with the larvae. Swap them every few weeks or when they’re covered. When far fewer flies get caught after using nematodes, you know it’s working. Keep traps indoors, as outside they catch helpful insects too.

A yellow sticky trap after a couple of days, covered in fungus gnats.
Nematodes: the best treatment
Nematodes are microscopic worms that hunt down fungus gnat larvae in the compost and kill them. Look for packs of Steinernema feltiae sold for fungus gnats or sciarid flies.
Use them when the compost is above 10C, which it will be in a heated home. Mix the pack with water as it says and water it into the compost. Keep the compost just moist for two weeks after. One dose usually brings a clear drop in flies over the following weeks. Repeat after 4-6 weeks if you still have problems.
Nematodes are alive, so keep the pack in the fridge and use it before the date on the pack. Check how many pots it treats.

Watering nematodes into the compost, where the larvae live.
Predatory mites and beetles
Predatory mites and rove beetles live in the compost and eat fungus gnat eggs, larvae and pupae. You can buy them by post from biological control suppliers. Sprinkle them on the compost as the instructions say.
They work more slowly than nematodes, but they stick around while there’s food. That makes them a good follow-up once nematodes have done the heavy lifting, or for collections where gnats keep coming back.
Is there a spray that kills fungus gnats?
Not one that solves the problem. The RHS doesn’t recommend any pesticides for fungus gnats, and sprays only hit the adults. Home remedies you’ll see online, like hydrogen peroxide, cinnamon or washing-up liquid, aren’t authorised pesticides in the UK. Stick to nematodes and predators.
Grit or sand on top
A 2-3cm layer of grit, coarse sand or perlite on the compost makes a dry barrier. Female gnats want damp compost to lay their eggs in, and the dry layer puts them off. Horticultural grit works best.
It stops new eggs but doesn’t kill larvae already there, so use nematodes too if you already have gnats. Once it’s on, it stays, and it also helps the compost hold on to moisture.

A layer of sand on top of the compost keeps gnats from laying eggs.
How to treat whitefly on houseplants
Whitefly needs a different approach, because it lives on the leaves, not in the compost.
Use a bug spray that’s authorised for whitefly on indoor plants, such as a fatty acid or plant oil product. Spray the undersides of all the leaves. These sprays don’t last, so repeat as the label says to catch the young ones as they hatch.
Yellow sticky traps catch adult whitefly too, so hang them at leaf height near the plant. For stubborn cases, a tiny parasitic wasp called Encarsia formosa works well in warm, bright spots. Release it early, as it isn’t an instant fix. Our organic pest control guide has more on natural controls.
How to prevent houseplant flies
Preventing them is easier and cheaper than getting rid of them.
Watering
Overwatering is the biggest cause. Let the top 3cm of compost dry out between waterings. Poke a finger in to check. Water less in autumn and winter when plants slow down. Watering from below, by standing the pot in a tray of water for 20-30 minutes, keeps the surface drier.
Compost
Heavy, fine compost stays wet at the surface for longer. Multipurpose compost also breaks down in the pot over time and stays soggy. Often it’s the compost, not just the watering.
The RHS suggests using a compost made for houseplants. A free-draining mix based on coir or bark dries faster at the surface. Mixing in some perlite or grit helps any compost drain better. Keep opened bags sealed and dry.
When repotting, swap out all the old compost. Shake it off, rinse the roots gently, and repot into fresh mix.

An open, airy mix dries out at the surface much faster, which is exactly what fungus gnats hate. Swap out all the old compost when you repot.
Keep new plants apart
New plants can bring gnat eggs home with them. Keep new buys in a separate room for 2-3 weeks with a sticky trap in the pot. If gnats show up, treat with nematodes before the plant joins your other houseplants.

Keep new plants on their own for two or three weeks with a sticky trap in the pot. If gnats turn up, you can deal with them before they spread.
Empty the saucers
Water sitting in saucers and decorative pots keeps compost soggy from the bottom up. Tip out saucers half an hour after watering. Pot feet or a few pebbles under the pot let air get underneath. This matters most for low light houseplants, which use water slowly.

Tip out saucers half an hour after watering and raise pots on little feet. It stops the compost staying soggy from the bottom up.
Quick prevention checklist
- Top 3cm of compost dries out between waterings
- Saucers emptied half an hour after watering
- Some perlite or grit mixed into the compost
- New plants kept apart for 2-3 weeks
- Grit on top of the compost of plants that get gnats
- Yellow sticky traps in place from October to March
- Dead leaves picked off the compost
- Every pot has drainage holes
Common mistakes with houseplant flies
Treating the wrong fly
Not all small flies are the same. Drying the compost won’t help with fruit flies from the fruit bowl. Nematodes won’t touch whitefly on the leaves. Check the table first.
Overwatering after nematodes
Nematodes need moist compost to move through, so the pack says to keep it damp for two weeks. Moist, not soggy. Too wet and you’re rolling out the red carpet for new gnats. Aim for a wrung-out sponge.
Using household fly spray on plants
Household fly sprays aren’t made or authorised for plants. They kill the odd adult and do nothing for the larvae. Only use products labelled for indoor plants.
Treating just one plant
Gnats fly from pot to pot. Treat one and leave six, and they just move house. Treat every plant in the room at the same time.
Ignoring drainage
Pots without drainage holes keep the bottom of the compost permanently wet, which is perfect for gnats. Use a plastic pot with holes inside the decorative one.
Caring for your plants during treatment
Fungus gnats rarely kill established houseplants, as the larvae mostly eat rotting bits in the compost.
Seedlings and cuttings are the exception. Their tiny roots can be eaten, and a bad infestation can kill them. If you’re propagating houseplants, keep them away from plants with gnats and use fresh compost.
Carry on caring for established plants as normal. Feed at half strength to help the roots recover. Check orchids and other plants in bark separately, as bark dries out differently from compost.
If a plant is badly hit and struggling, tip it out of its pot and shake off all the compost. Rinse the roots in lukewarm water, trim any damaged ones and repot in fresh compost with plenty of perlite. Put the old compost on an outdoor compost heap rather than reusing it.
When to get more help
Most problems clear within 6-8 weeks. Still got flies after two full rounds of nematodes and traps? Or do they seem to come from drains or walls rather than pots? Then call a pest controller.
The RHS guide to fungus gnats has more help with identification.
Frequently asked questions
Are houseplant flies harmful to humans?
No, they’re harmless to people. Fungus gnats don’t bite, sting or spread disease. They’re just annoying. Their larvae can nibble the roots of seedlings and cuttings, but rarely harm established plants.
Why do I suddenly have tiny flies around my houseplants?
Usually because the compost is staying too wet. Fungus gnats lay their eggs in damp compost. They often appear in autumn and winter, when plants need less water but get the same amount. A warm, centrally heated room keeps them breeding all winter.
Do fungus gnats live in all houseplant compost?
No, not until they move in. Most start when adults fly in from outside or come home on a new plant. Damp, open bags of compost can get them too. Letting the top 3cm dry out between waterings keeps numbers low.
How long does it take to get rid of houseplant flies?
Usually 6-8 weeks. Sticky traps start catching adults within a day or two, and nematodes get to work on the larvae within days. A new generation comes along about every month, so keep everything going for two rounds.
Can I use vinegar to trap houseplant flies?
It catches fruit flies, but not fungus gnats. Fungus gnats are drawn to damp compost, not fermenting fruit. If a vinegar trap is full of flies, you probably have fruit flies. Check the table above to see which fly you have.
Will repotting get rid of fungus gnats?
Yes, if you replace all the old compost. Shake off as much as you can, rinse the roots gently and repot into fresh, free-draining mix with some perlite added. It won’t stop them coming back if you keep overwatering, though.
Are nematodes safe for pets and children?
Yes, they only attack insect larvae. They’re tiny worms that live naturally in UK soil, and you just water them into the compost. Once they’re in, you can’t see them at all.
Our team produces practical UK gardening guidance from source research, contributor records and established horticultural practice. Editorial standards are overseen by Matt W.