The flies hovering around your mint plant are almost certainly fungus gnats or shore flies, both drawn to the moist, organically rich soil that potted herbs tend to sit in. Mint is a thirsty plant, so growers keep it well-watered, and that constant dampness creates ideal breeding conditions for tiny flies that lay their eggs in the top layer of soil. Getting rid of them is straightforward once you understand what they need to survive and cut off those conditions, but the approach depends on which fly you’re dealing with and how far the infestation has gone.
Which Flies Are on Your Mint
Not all small flies around a mint plant are the same insect, and misidentifying them leads to wasted effort. The most common culprits fall into a few distinct groups, each with different habits.
Fungus gnats are the likeliest suspect for indoor or potted mint. They’re tiny, dark-bodied flies that look like miniature mosquitoes and tend to hover just above the soil surface or fly in weak, erratic patterns near the plant. The adults themselves don’t do much damage, but their larvae live in the top few centimeters of soil and feed on fungi, decaying organic matter, and sometimes fine root hairs. A heavy infestation can stress a young or small mint plant.
Shore flies look superficially similar but are stockier, with shorter antennae and more confident, direct flight. They breed on algae that grows on persistently wet soil surfaces, so they show up when a pot has been sitting in standing water or a saucer that never dries out. You’ll often see them resting on the soil or pot rim rather than hovering in the air.
Whiteflies are a different problem entirely. They cluster on the undersides of leaves rather than around the soil and fly up in a cloud when you disturb the foliage. If your flies are coming from the leaves, not the dirt, whiteflies or aphids are the more likely issue.
Finally, you may occasionally spot hoverflies, also called syrphid flies, visiting your mint. These look like small bees or wasps, with yellow-and-black striped abdomens, and they hover with impressive precision. They’re actually beneficial: the adults pollinate flowers, and their larvae are voracious predators of aphids.
Why Mint Plants Attract Them
Mint’s growing preferences happen to overlap almost perfectly with fungus gnat breeding requirements. Mint likes consistent moisture, rich soil, and partial shade. Fungus gnats need damp organic soil to complete their life cycle, because the larvae depend on fungi and decomposing plant material in the growing medium for food. Every time you water your mint and the surface stays moist for more than a day or two, you’re maintaining a habitat where female gnats can lay eggs and larvae can thrive.
The type of potting mix matters, too. Research comparing coconut coir and sphagnum peat substrates found that fungus gnats infested both materials equally readily, with larvae recovered from all substrates tested. Coir does not inhibit fungus gnat development, so switching potting mixes alone won’t solve the problem.1HortTechnology. Fungus Gnat Population Development in Coconut Coir and Sphagnum peat-based Substrates The gnats aren’t picky about what organic medium they colonize as long as it stays moist.
Overwatering is the single biggest driver. Indoor herb growers tend to water on a schedule rather than checking whether the soil actually needs it, and mint’s reputation as a water-loving plant encourages heavy watering. Outdoors, mint in the ground can handle this because drainage is better, but potted mint sitting on a kitchen windowsill or balcony doesn’t have the same luxury. A saucer full of water underneath the pot keeps the bottom of the soil saturated, and that’s where larvae concentrate.
Why They’re More Than Just Annoying
Most people treat fungus gnats as a cosmetic nuisance, and for a healthy adult plant, a small number of them won’t cause visible damage. But there’s a less obvious reason to take them seriously: both fungus gnats and shore flies can spread plant diseases.
Research has shown that adult fungus gnats and moth flies can carry soilborne pathogens on their bodies, including Verticillium dahliae, Fusarium acuminatum, and Thielaviopsis basicola. Scanning electron microscopy confirmed that these insects externally acquire fungal spores after contact with contaminated material. Because the adults maintain high levels of inoculum on their body surfaces and can fly, they can disperse these fungi to other plants nearby.2Annals of Applied Biology. Acquisition, retention and dispersal of soilborne plant pathogenic fungi by fungus gnats and moth flies Shore flies perform the same trick: they’re attracted to sporulating fungal cultures and infected plant tissue, picking up pathogens both by ingestion and surface contamination.3Annals of Applied Biology. Attraction, acquisition, retention and spatiotemporal distribution of soilborne plant pathogenic fungi by shore flies
For a single mint plant on your windowsill, this risk is modest. But if you have several herbs or houseplants grouped together, fungus gnats moving freely between pots can introduce root rot or wilt pathogens from one infected plant to others that were previously healthy. Verticillium wilt, in particular, is a problem for many herbs in the mint family. Controlling the flies isn’t just about comfort; it protects the broader collection.
When the Flies Are Actually Helpful
If your mint is outdoors and flowering, the flies you’re seeing may not be pests at all. Hoverflies, the bee-mimicking flies mentioned earlier, are drawn to mint blossoms. Adult syrphid flies are important pollinators with high floral visitation rates, and their predatory larvae reduce aphid populations in both field and laboratory conditions.4PubMed. Dual ecosystem services of syrphid flies (Diptera: Syrphidae): pollinators and biological control agents If you grow mint alongside vegetables or fruit, hoverflies visiting the mint flowers are doing double duty: pollinating your garden and laying eggs near aphid colonies, where their larvae will feed.
The distinction is practical. If the flies are hovering near the flowers during the day and look like small bees, leave them alone. If they’re clustered near the soil, especially visible at dusk or when you water, those are fungus gnats and you should act.
Fix the Watering First
Before reaching for any product, change how you water. This single step eliminates most mild fungus gnat problems within a couple of weeks, because it breaks the breeding cycle. Allow the top inch or so of soil to dry out between waterings. Mint won’t suffer from a brief dry spell at the surface as long as the root zone stays reasonably moist deeper down. Bottom-watering, where you pour water into the saucer and let the plant wick it up from below, then dump any excess after 20 to 30 minutes, keeps the soil surface drier and makes it less hospitable for egg-laying.
Empty saucers and drip trays after every watering session. Standing water below the pot creates a permanently saturated zone at the bottom of the soil column, which is where fungus gnat larvae and shore fly algae both thrive. If your pot doesn’t have drainage holes, that’s an even more urgent fix than anything else on this list. Mint in a pot without drainage is basically a self-contained gnat nursery.
Improving airflow around the plant also helps. Outdoors this usually isn’t an issue, but indoors, mint tucked in a corner or surrounded by other plants stays damp longer. Moving the pot to a spot with better ventilation speeds surface drying.
Yellow Sticky Traps
Yellow sticky cards are a cheap, non-toxic way to knock down the adult population while you address the underlying moisture problem. They work because fungus gnats, shore flies, whiteflies, and aphids are all attracted to the color yellow. Place the cards horizontally just above the soil surface for fungus gnats, or vertically near the foliage for whiteflies. You’ll start seeing trapped adults within hours.
Greenhouse research found that yellow sticky cards caught substantially more fungus gnats, whiteflies, and aphids compared to clear traps, and that adding a small lime-green LED light to the card increased catches even further.5Insect Science. LIME GREEN LIGHT‐EMITTING DIODE EQUIPPED YELLOW STICKY CARD TRAPS FOR MONITORING WHITEFLIES, APHIDS AND FUNGUS GNATS IN GREENHOUSES You don’t need LEDs at home, but if you have a persistent problem in a grow tent or enclosed shelf, a small green light near the trap can make a real difference.
Sticky traps won’t solve an infestation on their own because they only catch adults. The larvae in the soil keep developing and emerging. But traps dramatically reduce the number of adults available to lay new eggs, which slows the cycle while your other interventions take hold.
Sand and Physical Soil Barriers
A layer of coarse sand, fine gravel, or decorative stone on top of the potting mix creates a physical barrier that discourages egg-laying. Female fungus gnats prefer to lay eggs directly on moist organic material, and a dry mineral layer on top makes the surface less attractive. Research on preventative treatments found that a sand topping gave significantly better control of shore flies compared to untreated pots.6New Zealand Plant Protection. Preventative treatments for control of fungus gnats and shore flies
The layer needs to be at least a centimeter thick and stay dry on the surface to work. If you overwater and the sand becomes saturated, flies will lay eggs right through it. Used properly, though, it’s a simple and lasting deterrent that also helps the soil surface dry faster between waterings.
The Diatomaceous Earth Myth
Diatomaceous earth is one of the most commonly recommended home remedies for fungus gnats, and it’s worth addressing specifically because the evidence does not support it. In controlled experiments, both dry and moist layers of diatomaceous earth generally did not prevent adult emergence or egg-laying by female fungus gnats. Researchers observed that the dry diatomaceous earth absorbed moisture from the growing medium and expanded, creating fissures that allowed larvae to pupate and females to lay eggs right through the barrier.7BioOne Complete (Journal of Economic Entomology). Effect of Diatomaceous Earth and Trichoderma harzianum T-22 (Rifai Strain KRL-AG2) on the Fungus Gnat Bradysia sp. nr. coprophila (Diptera: Sciaridae)
This makes intuitive sense once you think about it. Diatomaceous earth kills insects by damaging their waxy outer coating when dry, but it loses that property when wet. And the surface of a watered potted plant is wet most of the time. If you’ve been sprinkling diatomaceous earth on your mint’s soil and wondering why the gnats keep coming, this is why. Save it for dry applications elsewhere and use sand or gravel for your plant pots instead.
Biological Controls That Actually Work
For persistent infestations that don’t respond to watering changes and traps alone, biological controls offer effective, food-safe options that won’t leave residues on an herb you plan to eat.
Bacillus thuringiensis subspecies israelensis, usually sold as Bti, is a naturally occurring soil bacterium that produces proteins toxic to fly larvae but harmless to plants, people, and pets. You dissolve it in water and use it as a soil drench. The larvae ingest it and die within a day or two. In trials, Bti applied at weekly intervals produced some of the lowest fungus gnat numbers across all treatments tested.6New Zealand Plant Protection. Preventative treatments for control of fungus gnats and shore flies Products containing Bti are widely available under brand names like Mosquito Bits and Gnatrol. Crushing the granules and soaking them in water before applying gives faster results than sprinkling dry granules on the surface.
Beneficial nematodes are another strong option. Steinernema feltiae is a microscopic parasitic worm that hunts fungus gnat larvae in the soil. You mix the nematodes into water and drench the pot. Research on floriculture crops found that S. feltiae consistently suppressed fungus gnat populations in both the plant types tested compared to untreated controls.8Biological Control. Application rate and timing, potting medium, and host plant effects on the efficacy of Steinernema feltiae against the fungus gnat, Bradysia coprophila, in floriculture Nematodes are living organisms, so they need to be stored in the fridge and applied to pre-moistened soil for best results. They’re completely safe for edible plants.
Both Bti and nematodes target larvae, not adults. That’s actually what you want, because killing larvae breaks the breeding cycle at its source. Combine either one with sticky traps for the adults and you’re attacking the problem from both ends.
Soap Sprays and Neem Oil
If you’re dealing with soft-bodied insects on the foliage rather than the soil, such as whiteflies or aphids, insecticidal soap is a standard organic approach. Potassium salts of fatty acids dissolve the waxy coating on soft-bodied insects and kill them on contact. Research on insecticidal soap formulations found that soap-based emulsions penetrate and kill waxy insects within seconds, and that adding small amounts of citric acid can increase their effectiveness substantially.9ISHS Acta Horticulturae. USING FOOD-SAFE INGREDIENTS TO OPTIMIZE THE EFFICACY OF OIL-IN-WATER EMULSIONS OF ESSENTIAL OILS FOR CONTROL OF WAXY INSECTS
For mint specifically, test any spray on a few leaves first. Mint leaves are relatively hardy, but concentrated soap solutions can burn foliage, especially in direct sun. Spray in the evening, coat the undersides of leaves where pests cluster, and rinse the plant the next morning if you plan to harvest soon.
Neem oil works differently: it contains azadirachtin, which disrupts insect feeding and reproduction. It’s effective against a broad range of pests and is approved for organic use. As a soil drench, diluted neem oil can also discourage fungus gnat larvae. The downside is that neem has a strong, somewhat unpleasant smell and taste, and residues on mint leaves can affect flavor. If you’re growing mint for tea or cooking, use neem as a soil treatment rather than a foliar spray, or switch to Bti, which has no taste or odor.
Why Mint’s Oils Don’t Repel These Flies
There’s a common assumption that mint should repel insects on its own, given that peppermint oil is used in many commercial repellent products. This is true for some pests: concentrated mint essential oil can deter certain insects at close range. But the key word is “concentrated.” A living mint plant releases volatile compounds at levels far lower than what you’d get from applying pure essential oil, and those ambient levels aren’t enough to deter fungus gnats, which are responding to soil moisture and microbial cues rather than leaf chemistry.
Fungus gnats are drawn to the soil, not the plant itself. They’d colonize the same pot whether it held mint, basil, or nothing at all, as long as the growing medium was moist and rich in organic matter. The plant species growing in the pot is largely irrelevant to the fly’s decision to lay eggs. So while your mint’s aromatic leaves may discourage a moth from landing, they won’t do anything about the gnats breeding an inch below in the dirt.
Preventing Reinfestation
Once you’ve cleared an infestation, a few habits keep it from coming back. New bags of potting mix can harbor fungus gnat eggs or larvae, so inspect bagged soil before use. Some growers microwave or bake small quantities of potting mix to sterilize it before potting herbs, though this is impractical for large volumes and produces a memorable smell. A simpler precaution is to apply a Bti drench to freshly potted plants as a preventative, catching any larvae before they become adults.
Quarantine new plants before adding them to your collection. A new herb from a nursery or garden center can introduce gnats to an otherwise clean setup. Keep it in a separate room or area for a week or two, with a yellow sticky card nearby, to see whether adults appear before you place it next to your other plants.
Drainage is non-negotiable for long-term prevention. Every pot should have holes, every saucer should be emptied after watering, and the soil surface should dry between waterings. If you tend to overwater, consider switching to a terracotta pot, which wicks moisture through its walls and helps the soil dry more evenly than a glazed ceramic or plastic container. Mint tolerates terracotta well and actually benefits from the slight check on moisture that keeps root rot at bay.
Outdoor Mint and Different Fly Visitors
Outdoor mint planted in the ground rarely has serious fungus gnat problems, because natural soil drainage, predators, and environmental drying keep populations in check. The flies you see visiting outdoor mint are more often pollinators attracted to the flowers. Mint produces small, dense flower spikes that are rich in nectar and highly attractive to bees, butterflies, and hoverflies. If your outdoor mint is flowering and surrounded by small flies that look like bees, those are almost certainly syrphid flies doing useful work, and there’s no reason to intervene.
Outdoor potted mint, however, occupies a middle ground. The pot restricts drainage and creates conditions closer to indoor growing, so fungus gnats can still establish. Apply the same principles as indoor pots: ensure drainage, let the surface dry, and use Bti or nematodes if populations build. Wind and outdoor predators like ground beetles and spiders will help more than they do indoors, but they won’t eliminate a well-established colony on their own.
One scenario specific to outdoor settings is clusters of very small flies around mint that’s been damaged or is beginning to decay. Decomposing plant material attracts a wider range of flies, including various species of vinegar flies and blow flies. If your mint has yellowing, mushy stems at the base, the flies may be signaling a rot problem rather than a simple moisture issue. Trim away dead material, improve air circulation around the base of the plant, and reduce watering until new healthy growth appears.