A few tiny black flies circling a rack can be dismissed as a nuisance—until they keep appearing next to seedling trays. Fungus gnats are especially common around persistently damp growing media. The adults are easy to notice, but their immature stages are in the medium. A good response begins by identifying the insect, finding the moisture source and keeping controls away from edible leaves.
This guide is for home growers and small microgreens racks. It distinguishes monitoring from control and explains why many greenhouse insecticide recommendations for ornamental plants do not automatically apply to microgreens harvested for food.

First: make sure they really are fungus gnats
| Clue | Fungus gnat | Look-alike to consider |
|---|---|---|
| Adult shape | Small, dark, mosquito-like fly with long legs and long antennae | Shore flies are stockier, with short antennae; fruit flies have a different body shape |
| Where you see them | Hopping or flying weakly near damp media, pots or windows | Shore flies often accompany algae and persistently wet greenhouse surfaces |
| Larva in medium | Small translucent, legless larva with a dark head capsule | Many other tiny organisms live in moist media; do not identify them from color alone |
| Visible crop injury | Adults may only be a nuisance; high larval pressure can injure delicate roots | Stunted growth and wilting have many other causes, including seedling disease |
University of California IPM and University of Connecticut greenhouse IPM describe fungus gnats as members of the Sciaridae group, whose larvae feed primarily on fungi and organic matter but may also damage tender roots. A couple of adults do not prove a crop is infested or unsafe; persistent adults and larvae in the medium are more informative.
A simple, food-aware monitoring plan
- Look at the media surface at watering time. Note whether flies emerge from a specific tray, a nearby houseplant, a wet media bag or a damp drain.
- Put a numbered yellow sticky card near the rack, away from harvestable foliage. Sticky cards track adults and trends; they are not proof that larvae have been eliminated. Do not allow adhesive, trapped insects or card fragments to touch edible greens.
- Check a representative non-harvest monitoring pot if necessary. University Extension programs describe using a small raw potato piece on media to attract larvae, then examining it after about 48 hours. For a food production rack, do this in a segregated monitoring container—not on a tray you plan to harvest.
- Inspect twice each week. Record whether counts are rising, stable or falling. Keep the same trap position and counting interval so trends are comparable.
- Check new inputs. Look for flies or excessively wet clumps in newly opened growing medium and inspect nearby ornamentals before assuming microgreens seed is the source.
Fix the conditions that let gnats reproduce
1. Stop holding standing water under the rack
Empty and clean water catch trays and runoff containers. Eliminate leaks under shelving, soaked cardboard and wet organic debris. Maintain enough moisture for germinating microgreens, but avoid an indefinitely saturated medium. The goal is balanced moisture, not a dried-out crop. Use the watering assessment guide and bottom-watering instructions to tune the routine.
2. Remove breeding sites between batches
Keep fresh growing medium bagged, dry and off the floor; remove spent trays promptly and clean spilled medium. Don’t park used media or cull piles beside the next batch. Pay special attention to poorly drained corners and algae where water sits.
3. Separate ornamental plants and food-growing surfaces
A nearby overwatered houseplant can be an adult-gnat source even when the microgreen tray itself looks fine. Check those containers, but avoid carrying pesticides, sticky residues or potting soil from ornamentals onto food-production equipment.
4. Use monitoring to decide whether a bigger response is needed
A single fly caught one day is not a reason to spray an edible crop. Increasing adult counts, obvious larvae and damaged root zones call for a more deliberate management plan. UC IPM emphasizes moisture reduction and sanitation as central controls; traps mainly help you measure adult activity.
What about beneficial nematodes, Bti and other controls?
For ornamental and greenhouse production, university IPM programs discuss beneficial nematodes such as Steinernema feltiae, predatory mites and Bacillus thuringiensis israelensis (Bti) products targeting larvae. But a product that is discussed for houseplants or greenhouse ornamentals is not automatically permitted for edible microgreens. Registrations, crop labels, application sites, withholding intervals and local rules vary. Ask your local Extension office or a qualified pest-management professional and read the actual product label before use on or near a harvestable food crop.
Avoid household flying-insect sprays, foggers, essential-oil mixtures, dish-soap drenches and unlabeled pesticide uses around ready-to-eat microgreens. Sticky traps are for monitoring; avoid contact with crop tissue. In a small setup, fixing moisture and sanitation and starting clean often makes more sense than reaching for a chemical treatment.
Compare catches over the same amount of time
Write the date a clean sticky card goes up and the date you count or replace it. Keep the card type, position and distance from the suspected source consistent. UC IPM explains that yellow cards catch adults; interpreting the trend still requires comparable observations.
Worked example: 15 adults over five days is 15 ÷ 5 = 3 adults per card-day. A later card with 12 adults over two days is 12 ÷ 2 = 6 per card-day. The second card has fewer total insects but a higher catch rate. These invented numbers demonstrate the calculation; they are not treatment thresholds.
If you move the card, add nearby plants or change the fan position, mark that on the record and start a new comparison. If a card becomes coated with dust or too crowded to count, replace it and record the shortened interval. Pair the count with observations of larvae, wet debris and affected trays; a falling adult count cannot establish that a crop is uncontaminated or that immature gnats are gone.
Seven-day troubleshooting worksheet
| When | Action | What to record |
|---|---|---|
| Day 1 | Identify adults; inspect damp media, drains, houseplants and new substrate | Likely source; trap locations; photo of insect |
| Day 2 | Correct standing water and clean discarded medium | Watering and cleanup changes |
| Days 3–4 | Check traps and non-harvest monitoring media | Adults per card; whether larvae seen |
| Days 5–6 | Maintain safe crop moisture; verify no fly or adhesive material enters harvest zone | Drainage observations; insect activity |
| Day 7 | Recount traps and compare with day 1; decide whether expert help is needed | Trend, suspected source and next step |
The seven-day plan is a monitoring interval, not a promise of eradication. University of Connecticut reports that a complete fungus-gnat life cycle can take several weeks depending on temperature. A falling adult count after one week does not prove eggs and larvae are gone.
When does an insect problem become a food-safety issue?
Fungus gnats are not the same thing as the human pathogens addressed by produce-safety guidance, and adult sightings alone do not establish microbial contamination. Nevertheless, insect bodies, droppings, contaminated water and dirty growing areas have no place in a product intended to be eaten raw. If insects or their residues have substantially contaminated the edible crop, do not sell or serve that tray. Clean affected surfaces and review handling practices. See Food Safety Basics and, if selling, batch tracing from seed to harvest.
For farms subject to the U.S. Produce Safety Rule, microgreens are generally treated as produce rather than sprouts grown under the specific sprout standards. Applicability and exemptions depend on the operation; consult the relevant state produce-safety program rather than treating a web article as a regulatory determination.
Common questions
Will a fan get rid of fungus gnats? Not reliably. Air movement can help with persistently damp conditions but does not remove larvae from growing media. See the airflow guide.
Will yellow traps eliminate the infestation? They catch some adults and help show trends. They do not reliably control eggs and larvae on their own.
Can I just let the whole tray dry completely? No. Microgreens need sufficient moisture to grow. Correct standing water and excessive wetness while maintaining the crop’s actual moisture requirements.
Do all gnats come from the seed? No. Adults can arrive from wet potting medium, houseplants or nearby breeding sites. Investigate before blaming a seed lot.
Are a few flying adults an automatic reason to throw away a tray? Not necessarily. Evaluate whether edible tissue or equipment was contaminated, whether larvae are present, and whether normal harvest hygiene can be maintained. When contamination is evident or safety is uncertain, discard affected produce.
Source notes and further reading
The identification and integrated-pest-management guidance below comes from university programs. The specific food-contact precautions are conservative adaptations for short-cycle produce eaten raw, not a claim of microgreens-specific efficacy trials.
- UC Statewide IPM — Fungus Gnats (identification, moisture control, life cycle, monitoring and biological controls)
- University of Connecticut Extension — Managing Fungus Gnats in the Greenhouse (scouting and moisture controls)
- University of Minnesota Extension — Managing Insects on Indoor Plants (diagnosis and traps)
- FDA — What the Produce Safety Rule Means for Consumers (general produce-safety context)



