how to get rid of fruit flies and gnats (and what the difference is)
All featured products are curated independently by our editors. When you buy something through our retail links, we may receive a commission.

How do you get rid of fruit flies and gnats? Read on to find out—and also learn how these insects differ (because they’re actually not the same thing).

Infestations of tiny gnats or fruit flies are a major annoyance, and may pose a risk to human health. It’s not very appetizing to pick up a perfectly ripe banana, only to have a cloud of tiny bugs swarm all over the kitchen. And it’s no fun when you are watering your beautiful houseplant to discover little creepy crawlies all over the soil. If you’re dealing with an infestation in your home or office, keep reading to learn the best ways to get rid of gnats and fruit flies.

It’s important to know that gnats and fruit flies are two different pests. In order to eradicate them, you need to know which you are dealing with. Don’t worry, they’re pretty easy to distinguish. They look different from one another, and they live in different habitats.

Fruit Flies

Fruit flies range in color from black to tan. They also have relatively big red eyes. They have a fairly rounded shape, kind of like a tiny house fly. Adult fruit flies are attracted to ripe fruit and rotting foods, so it’s pretty common to see them around countertops and trash cans. They breed in moist areas, like sink drains, garbage disposals, or wine and beer bottles awaiting recycling.

Fruit flies develop in four stages, egg, larva, pupa, and adult. Adult females lay eggs on the surface of over-ripe fruit or other moist organic matter. One day later the larva emerges. The larva feeds for about a week before entering the pupa phase. After six days the adult emerges to live and breed for several weeks.

Fungus Gnats

Gnats are darker, either black or gray, and have tiny eyes that you won’t easily see. They have an elongated shape and legs that hang below their bodies, like the shape of a mosquito. Fungus gnats are soil dwellers. They often nest in the soil of potted plants.

Fungus gnats have a 4-stage life cycle: egg, larva, pupa, and adult. Adults are mostly a nuisance, flying around well lit areas and landing on people, food, and anything else. Adult females lay up to 300 eggs on the soil surface. After hatching, larvae feed on organic matter in the soil, including fungus and plant roots, for about two weeks before entering the pupa phase. The total time from egg to adult is about four weeks. Adults live and breed for about a week.

The Dangers of Fruit Flies & Gnats

If you have an infestation, you should get it under control right away. Fungus gnats damage the roots of house plants. Fruit flies spread salmonella, e. Coli, listeria, and other bacteria that cause food borne illnesses. Use your knowledge of their habitats and life cycles to quickly eliminate the infestation.

How to Get Rid of Fruit Flies

how to fight food waste

Peter Dazeley / The Image Bank / Getty Images

Prevent fruit fly infestations with proper food storage, and consistent kitchen sanitation. Store ripening fruit and veggies inside closed paper bags. Use up, preserve, or dispose of countertop fruit and veggies before they become overripe. Rinse out food and beverage containers before disposing of them. Dispose of kitchen waste daily. If you don’t want to take out a partially filled trash bag, be sure it is tightly covered. Never leave dirty dishes overnight. Clean kitchen drains and garbage disposal monthly.

To eliminate a fruit fly infestation, begin with a thorough clean up. Clean all kitchen surfaces: countertops, cabinet faces, refrigerator, and stove. Clean garbage and recycling containers inside and out. Apply prevention measures listed above.

Set fruit fly traps to monitor progress. You can use either sticky traps from the hardware store, or homemade fly traps. Simply put a little wine or sweetened vinegar at the bottom of a glass jar, cover tightly with cling wrap, and punch two or three toothpick size holes in the plastic. If you maintain the cleanliness protocols, the number of adults you catch daily will dwindle over the course of several weeks.

You can also try a paper cone style trap:

How to Get Rid of Gnats

Fungus gnats are attracted to the moist surface of house plant soil. Reduce their attraction by allowing the soil surface to dry out between waterings. Applying a 1-inch layer of fast-drying mulch such as decorative stone or dried Spanish moss may also help.

When you discover an infestation of fungus gnats, begin monitoring and treatment by placing sticky traps to capture adults. Cut the yellow sticky traps into 2-inch pieces, attach them to skewers, and place one in each plant pot.

Gideal 20-Pack Dual-Sided Yellow Sticky Traps, $10.99 from Amazon

Buy Now

Also, place small chunks of raw potato onto the soil surface to attract larvae that may be lurking in the soil. Dispose of infested chunks every couple of days.

If the problem persists for a week or two, treat the affected and adjacent houseplants with Bacillus thuringiensis israelensis (Bti). Bti, an active ingredient in products like Mosquito Bits and Gnatrol, is a biological larva killer that is non-toxic and does not persist. You’ll have to apply it every five days for a few weeks to fully control the infestation.

Got Another Issue?

7 Ways to Get Rid of Ants in the Kitchen

Header image courtesy of Tetra Images / Getty Images

See more articles