Most gnats are not truly nocturnal fliers, but the answer depends heavily on which gnat you are dealing with. The small flies lumped under the common name “gnat” include fungus gnats, eye gnats, biting midges, black flies, and no-see-ums, and each group follows its own daily schedule shaped by light, temperature, and humidity. Some peak at dawn and dusk, others shut down almost entirely after dark, and a few will swarm around porch lights well into the evening. Understanding which pattern applies to the gnats bothering you is the key to figuring out what draws them in and how to make them stop.
Why “Gnats” Is a Loose Label
Before sorting out who flies when, it helps to know that “gnat” is not a single species or even a single family. In everyday conversation the word covers at least four distinct groups of tiny flies: fungus gnats (family Sciaridae), eye gnats (genus Hippelates), biting midges or no-see-ums (genus Culicoides), and black flies (family Simuliidae). A few people also call fruit flies and drain flies “gnats.” These insects differ in where they breed, what they eat, whether they bite, and when they are active. A fungus gnat hovering near your houseplants has almost nothing in common with a biting midge chewing on your ankle at a lakeside campsite, and the strategies that work against one group can be useless against the other.
Which Gnats Fly at Night and Which Do Not
Eye gnats, the tiny flies that hover around your face outdoors, have a clear minimum light requirement for flight. Studies on two Hippelates species found that flight stopped below about 5 foot-candles of light, a level roughly equivalent to deep twilight.1Journal of Medical Entomology. Flight of the Eye Gnat, Hippelates Pusio (Diptera: Chloropidae): Effect of Temperature, Light, Moisture and Wind Velocity A second species in the same genus showed an almost identical threshold.2Journal of Medical Entomology. Flight of the Eye Gnat, Hippelates Pallipes (Diptera: Chloropidae): Correlation with Temperature, Light, Moisture and Wind Velocity Once the sun is fully down and ambient light drops below that level, these gnats land and stay put. If you are being swarmed by tiny flies that target your eyes, ears, and nostrils, and it only happens during the day, you are almost certainly dealing with eye gnats.
Biting midges tell a different story. Female Culicoides impunctatus, one of the most studied biting midge species, showed a bimodal activity pattern with peaks at dawn and dusk, the dawn peak between about 5:00 and 7:00 a.m. being the strongest.3PubMed. Diel flight periodicity of the biting midge Culicoides impunctatus and the effects of meteorological conditions That means they are crepuscular, most active in the transition zones between day and night. They can and do bite in near-darkness around dusk and pre-dawn, which often feels like nighttime to anyone standing outside. On overcast or humid evenings, biting midge activity can bleed well past sunset.
Black flies follow a roughly similar pattern, with peak activity one to two hours after dawn and in the hour before sunset. Field studies in Quebec forests found that flight activity depended on light intensity as long as temperature stayed above about 7°C and wind speed remained low. At night, black flies moved upward to rest in the tops of trees, likely tracking the slightly higher ambient light at canopy level just before full darkness.4Canadian Journal of Zoology. DIURNAL BEHAVIOR AND BITING HABITS OF BLACK FLIES (DIPTERA: SIMULIIDAE) IN THE FORESTS OF QUEBEC In other words, they are not flying around biting people at midnight, but they can be aggressive as the last light fades.
Fungus gnats are the exception that most closely approaches true nighttime activity. These are the small dark flies that breed in damp potting soil and hover around houseplants or greenhouse benches. Because they live indoors or in sheltered environments with artificial lighting, the outdoor day-night cycle matters less. They respond strongly to certain wavelengths of light and can be active whenever conditions suit them, including after dark if a lamp or window is nearby.
What Attracts Gnats to You and Your Home
Different gnat groups respond to different cues, but the broad categories are light, carbon dioxide, body odors, and moisture. Knowing which cue matters most for the gnats in your area helps you prioritize control measures.
Light
Fungus gnats are strongly drawn to ultraviolet and green-yellow wavelengths. In laboratory choice experiments, the black fungus gnat Bradysia difformis was most attracted to UV light around 382 nanometers, followed by green-yellow light in the 532 to 592 nanometer range. Combining UV and yellow LEDs in a trap outperformed either wavelength alone and also outperformed standard yellow sticky traps.5Entomologia Experimentalis et Applicata. Visual orientation of the black fungus gnat, Bradysia difformis, explored using LEDs Another fungus gnat species, Lycoriella ingenua, showed a similar two-peaked sensitivity with maxima in the UV and green ranges. When given a choice of five LED colors, about 61% of gnats chose the UV-lit chamber in one experiment, and in a separate trial roughly 41% chose green light with another 25% choosing blue.6PubMed Central. In search of the spectral composition of an effective light trap for the mushroom pest Lycoriella ingenua (Diptera: Sciaridae)
This dual sensitivity to UV and green light explains why fungus gnats cluster around certain types of indoor lighting. Standard warm-white LEDs, which have relatively little UV output, are less attractive than cool-white fluorescents or older tube lights that emit more energy in the blue-UV range. If gnats are gathering around specific lamps in your home, switching to a warmer color temperature can reduce the draw.
Biting midges and black flies also orient to light, but their stronger motivator is the host’s body. Light becomes more relevant to these species at dawn and dusk, when changing light intensity is the environmental clock that triggers their activity bursts.
Carbon Dioxide and Body Chemistry
Biting gnats locate hosts partly through the carbon dioxide plume you exhale. This is the same mechanism mosquitoes rely on, and it works at a distance of several meters. Once closer, skin volatiles take over as the primary homing signal. Research on mosquitoes, which share the blood-feeding attraction pathway with biting midges, found that certain human skin compounds can dramatically increase or reduce landing. Specific fatty acids produced by skin bacteria reduced mosquito landing by as much as 80 to nearly 100%, while other volatile blends made the host more attractive.7PubMed Central. Identification of human skin microbiome odorants that manipulate mosquito landing behavior – Section: Results Although that study focused on mosquitoes, the overlap in host-seeking behavior between mosquitoes and biting midges means the general principle applies: your individual body chemistry, influenced by your skin microbiome, sweat composition, and even diet, affects how attractive you are to biting gnats.
Moisture and Organic Decay
Fungus gnats are drawn to damp organic matter because that is where they lay their eggs. Overwatered houseplants, compost bins, wet mulch, and clogged drains all offer the moist, fungi-rich environment their larvae need. Some fungus gnat species are even attracted to specific chemical compounds produced by fungi. Bradysia optata, for instance, is attracted to cantharidin, a terpenoid compound, possibly because gnats mistake it for structurally similar fungal metabolites that signal a good site for mating and egg-laying.8Entomologia Experimentalis et Applicata. Attraction of the fungus gnat Bradysia optata to cantharidin The practical takeaway: if you have a fungus gnat problem, the solution almost always starts with drying out their breeding site rather than chasing adult flies.
Weather and Environmental Conditions That Drive Gnat Activity
Temperature, humidity, and wind speed determine whether gnats fly at all on a given day, regardless of the time. Eye gnats require a minimum of about 17 to 18°C to take flight.1Journal of Medical Entomology. Flight of the Eye Gnat, Hippelates Pusio (Diptera: Chloropidae): Effect of Temperature, Light, Moisture and Wind Velocity Black flies in Quebec forests needed temperatures above roughly 7°C, with relative humidity above 50% and wind speed below about 2 miles per hour.4Canadian Journal of Zoology. DIURNAL BEHAVIOR AND BITING HABITS OF BLACK FLIES (DIPTERA: SIMULIIDAE) IN THE FORESTS OF QUEBEC Wind is especially relevant because gnats are weak fliers. Even a moderate breeze grounds most species, which is why screened porches and fans are surprisingly effective defenses.
Approaching storms can actually spike gnat activity. The Quebec black fly research noted that flight increased before thunderstorms and rain, and the surge seemed tied more to the drop in light intensity than to changes in barometric pressure or humidity.4Canadian Journal of Zoology. DIURNAL BEHAVIOR AND BITING HABITS OF BLACK FLIES (DIPTERA: SIMULIIDAE) IN THE FORESTS OF QUEBEC If you have noticed gnats becoming unusually aggressive on a cloudy afternoon, the dimming light is probably mimicking dusk conditions and triggering feeding behavior early.
For eye gnats, the moisture threshold is defined by vapor pressure deficit rather than relative humidity, meaning it is the drying power of the air that matters. When the air is too dry, eye gnats stay grounded.1Journal of Medical Entomology. Flight of the Eye Gnat, Hippelates Pusio (Diptera: Chloropidae): Effect of Temperature, Light, Moisture and Wind Velocity This partly explains why eye gnat problems peak in warm, humid climates and irrigated agricultural areas where the combination of warmth and moisture is nearly constant during growing season.
How Artificial Light Changes the Rules After Dark
Even species that normally stop flying in darkness can be coaxed into nighttime activity by artificial light. Porch lights, landscape lighting, illuminated signs, and light spilling from windows create pockets of brightness well above the flight thresholds that would otherwise ground gnats after sunset. Researchers have documented wide-ranging effects of artificial light at night on crepuscular and nocturnal insects, including disrupted flight patterns, altered feeding behavior, and changes in where insects congregate.9PubMed Central. The impact of artificial light at night on nocturnal insects: A review and synthesis
For a homeowner, this means that if gnats seem active after dark around your house, artificial lighting is the most likely explanation. A bright white security light or a string of cool-white patio LEDs can attract gnats that would otherwise be resting. Switching to warm amber or yellow bulbs, which emit less of the short-wavelength light gnats find attractive, reduces the draw considerably. Some hardware stores sell “bug light” bulbs specifically for this purpose; they work not by repelling insects but by emitting wavelengths that most flying insects see poorly.
How to Stop Gnats in Practice
Control measures fall into three buckets: reducing breeding habitat, blocking or trapping adults, and changing your environment to make it less attractive. The right approach depends on which gnats you are dealing with.
Fungus Gnats Indoors
Let the top inch or two of potting soil dry between waterings. Fungus gnat larvae need continuously moist soil; a dry surface layer kills them or prevents eggs from hatching. For heavy infestations, a layer of coarse sand or fine gravel on the soil surface creates a physical barrier. Sticky traps placed near the soil line catch adults effectively, and yellow traps work better than other colors for these species. A trap that combines UV and yellow light outperforms plain sticky cards, as the lab research on Bradysia difformis confirmed.5Entomologia Experimentalis et Applicata. Visual orientation of the black fungus gnat, Bradysia difformis, explored using LEDs Biological control with Bacillus thuringiensis israelensis (Bti), a soil bacterium sold as mosquito dunks or gnat-specific granules, kills larvae without harming plants.
Biting Midges and No-See-Ums Outdoors
Fine mesh screens are the single most reliable defense. Standard window screens have openings too large to block no-see-ums; you need mesh rated at 16 by 16 threads per centimeter or finer. Fans on porches and patios create enough wind to ground these weak fliers, and even a small personal fan directed at your legs can cut biting rates sharply. Because biting midges peak at dawn and dusk, timing outdoor activities for midday avoids the worst waves. DEET-based repellents remain the most effective topical defense, though picaridin and oil of lemon eucalyptus also provide meaningful protection. Eliminating standing water and saturated soil near your home reduces local breeding, but biting midges can fly from breeding sites hundreds of meters away, so source reduction on your own property only goes so far.
Eye Gnats
Eye gnats breed in loose, freshly tilled soil rich in organic matter, so farms and gardens near sandy soil are prime habitat. You cannot easily eliminate their breeding grounds because the larvae live dispersed in soil rather than concentrated in puddles. Personal protection, meaning repellent and hats with head nets, is the most practical defense in areas where eye gnats are heavy. Keeping compost piles covered and reducing bare, moist soil surfaces around your home helps somewhat.
General Measures for Any Gnat Type
- Fix moisture problems: leaking outdoor faucets, clogged gutters, and overirrigated lawns create breeding habitat for multiple gnat species.
- Switch outdoor lighting: replace cool-white bulbs with warm amber or sodium-vapor bulbs, and position lights away from doors and seating areas so the insects congregate elsewhere.
- Use fans: any air movement above a gentle breeze disrupts gnat flight. Ceiling fans on porches, clip-on fans at campsites, and even handheld battery fans all help.
- Time your activities: if biting gnats are the issue, the worst periods are typically the hour around sunrise and the hour around sunset. Plan accordingly when possible.
Why Some People Seem to Attract More Gnats
If you have ever stood next to someone who is unbothered while you are covered in biting gnats, the difference is real and not imagined. Individual variation in skin chemistry, particularly the cocktail of fatty acids, lactic acid, and ammonia your skin releases, creates a scent profile that biting insects read as more or less appealing. The mosquito research that identified specific skin microbiome compounds capable of reducing landing by up to nearly 100% illustrates how powerful these chemical signals can be.7PubMed Central. Identification of human skin microbiome odorants that manipulate mosquito landing behavior – Section: Results Carbon dioxide output also varies with body size, metabolic rate, and exertion, so larger or more active people tend to attract more biting gnats. Pregnancy and alcohol consumption both increase COâ‚‚ output and skin temperature, which together can make you a bigger target. Dark clothing may also play a role, as many biting flies use visual contrast against the sky to locate hosts, and a dark silhouette stands out more than a light one.
Drain Flies and Other Mistaken-Identity Gnats
Not everything tiny flying around your kitchen sink is a gnat. Drain flies, also called moth flies, are fuzzy-winged insects that breed in the organic film inside drains and sewage pipes. They are poor fliers, usually just hopping short distances, and are nocturnal in habit: you spot them on walls near drains at night or early morning. Fruit flies, meanwhile, are attracted to fermenting produce and vinegar-like odors, not light or moisture per se. A classic apple cider vinegar trap with a drop of dish soap catches fruit flies effectively but does almost nothing for fungus gnats, which are drawn to soil and light rather than fermented smells. Correctly identifying which insect you have saves a lot of wasted effort with the wrong trap or treatment.
A quick visual guide: fungus gnats are dark, slender, and mosquito-like in shape, usually seen near potted plants. Fruit flies are rounder, tan or brown, with red eyes, and hover near fruit bowls or trash cans. Drain flies are hairy, moth-shaped, and sit flat against walls near plumbing. Eye gnats are tiny, shiny black, and fly at your face outdoors. Biting midges are nearly invisible, leaving itchy welts out of proportion to their size, and peak around sunrise and sunset. Matching the description to the insect in your space points you toward the right control strategy without guessing.