How to Get Rid of Gnats (in Your House) – The Definite Guide

Cartoon set of different insects on white background.Gnats. Fruit flies. It doesn’t matter what you call them, these tiny flying bugs are a giant nuisance. And when you’re dealing with an infestation, the last thing you want to do is try to inspect one of these bugs up close.

But if you’d rather not share your home with a pack of bugs, you just might have to get up-close-and-personal with one to see what you’re dealing with. While many of the same extermination methods will work for both types of insects, some are better than others for each type.

Let’s take a look at the difference between these bugs before we talk about ways to exterminate them.

Fruit Flies Vs Gnats: What’s the Difference?

Despite what you might have heard, fruit flies and gnats aren’t the same thing. But it’s easy to see why people confuse the two. Both of these flying insects are so tiny, it’s difficult to really tell the difference between them without a magnifying glass (go ahead, try it out for yourself).

Fruit flies are a bit larger than gnats, although both insects are small. The most common fruit fly species measures about one-eighth of an inch, and has a brownish-colored head with a black tail and red eyes.

Fungus gnats, on the other hand, are completely black in color and are just one-sixth of an inch in size. While they’re really tiny, gnats have long, gangly legs that are very noticeable when they’re flying.

Each of these insects belong to different families in the Diptera order.

Fruit flies and gnats also have different life cycles. Gnat eggs are laid in the soil of houseplants, and hatch in just four days. Gnats remain in the pupal stage for one week before developing into an adult. Adult gnats live for just one week on average, during which females can lay up to 150 eggs.

Fruit fly larvae are dependent on rotten food to survive. Females can lay 500 eggs before death.

What Attracts Gnats?

Dark-winged fungus gnat on flower bud on purple background.Why do you have a gnat infestation in the first place? And why do they seem to be attracted to your face? Yes, gnats love to fly in your face.

Scent has a lot to do with it. Perfume, body lotion and even the laundry detergent you use to wash your clothes can attract gnats. These tiny bugs are attracted to sweet and/or floral scents, depending on the type of gnat.

Fungus gnats are in your home because of, well, fungus. More often than not, the problem is a house plant (or two) with overly-moist soil.

Other species of gnats bugs are attracted to body heat, and some are attracted to moisture – which can include the mucous around your eyes and nose (gross).

If you have fruit or vegetables lying around uncovered in your home, you may be attracting gnats this way. Houseplants and fresh flowers are other attractants. These flies are also attracted to rotting garbage.

Read more about Gnats

What About the Gnats Outside My Home?

If you have gnats hanging around outside your home, there is something in your yard that’s attracting them. This may be a fruit tree or your vegetable garden. Flowers may also attract them.

If you’re over-watering your flowers or lawn, fungus and mold (as well as the moisture) may be attracting them.

Some gnats are also attracted to light, so your outdoor lights may be luring them in.

What Causes Fruit Flies?

Single fruit fly on the white.

What attracts fruit flies? You guessed it – fruit. Have you ever taken home a ripe cantaloupe or bunch of bananas and found a horde of flying bugs in your home days later? Those are probably fruit flies.

And while it may seem like these guys just appeared overnight out of thin air, they didn’t. Remember, fruit flies are exceptionally small, and their sense of smell is impeccable. They can smell the fruit on your counter from a good distance away, and once they catch onto the scent, they’ll do all that they can to get in your home. The task shouldn’t be too difficult if you have an open window or step outside for a moment.

Fruit flies can get in through the screens on your windows and crevices in your home. And the moment you open your front door, you’re inviting them right inside.

A horde of fruit flies can also hitch a ride home with you, hiding out on your vegetables and fruits. How? These flies actually lay eggs on the skin of fruit that is very ripe or already fermenting.

Long story short: fruit flies are in your home – or outside your home for that matter – because you have overripe or fermenting produce somewhere.

How Long Do Gnats Live?

Worried that gnats will stick around for weeks or months? You’ll be happy to hear that these pesky bugs have a very short lifespan.

So, even if your efforts to kill them don’t work right away, you can be sure that they’ll be out of your life for good in just a week or two (as long as you get rid of the food that’s attracting them).

Gnats go through four life stages: egg, larvae, pupae and adult. And while they may not have long lifespans, their ability to reproduce is impressive.

How long do gnats live? That depends on the species.

  • Adult fruit flies can live 40-50 days or less, and they can take 30-65 days to complete a life cycle.
  • Adult phorid flies live 8-14 days, and their life cycle can take anywhere from 8 to 37 days to complete.
  • Adult fungus gnat scan live 1-2 weeks and complete a life cycle in 30 days or less.
  • Adult moth flies only live about 14 days, and they complete their life cycle in 7-21 days.

Although the fruit fly has a short lifespan, females have the potential to lay more than 500 eggs in their lifetimes.

If you have an infestation of gnats and you don’t take steps to fix the problem, you could wind up with an uncontrollable population. Yes, they don’t live long, but their ability to proliferate is impressive.

How to Get Rid of Indoor Gnats

You now know the difference between gnats and fruit flies. You even know what attracts them. So how do you get rid of gnats in your house?

If you want to learn how to get rid of gnats in the house (in the kitchen, in the bathroom, in the living room – wherever), read on. We’re going to share our tried-and-true method for getting rid of these flying bugs: a homemade trap.

Homemade Gnat Trap Killer

The best gnat trap is simple, cheap and easy to make yourself. And it will get rid of the gnats in your home in a snap.

Here’s what you’ll need:

  • A mason jar with a lid
  • Vinegar (gnats love apple cider vinegar)
  • Nail or screw

These are all things you probably have laying around your home. If you don’t have a mason jar, any old jar will work just fine as long as it has a lid.

  1. Fill the jar about half-way with apple cider vinegar. If you don’t have apple cider vinegar, you can use regular white vinegar. Just add a few drops of soap to make the trap more enticing.
  2. Seal the lid on the jar.
  3. Poke tiny holes in the lid with a nail or screw.

The gnats will be able to get into the jar, but they won’t be able to get out. Gnats are extremely attracted to vinegar. They love honey, too, so feel free to add a drop or two of honey if you want an even more effective trap.

If you’re wondering how to get rid of house flies, this trick won’t work. People often confuse house flies for gnats, but these are two different things. You’ll need a hanging sticky trap (also known as flypaper) to get rid of flies in your home.

How to Get Rid of Gnats in the Kitchen

Clean Up

Gnats love rotting produce, which is why you typically find them in your kitchen. If you want to evict them from the room, start by cleaning up.

Chances are, you have rotting fruit or vegetables on your countertop or in a cabinet. Maybe you were out of town, or maybe you forgot about the bunch of bananas that fell behind the fruit bowl.

Either way, the first step is to locate the source (i.e. the rotting food) of the problem. Toss the rotting food in the trash, and keep all produce in the refrigerator for the time-being until all of the gnats are gone.

Wash Your Produce

Make sure that you wash your produce as soon as you come home from the store. There may be eggs or tiny larvae on the surface of your fruits and vegetables. 

Washing them and storing them in sealed bags or containers can help eliminate a gnat infestation and prevent them from coming back.

Check Your Plumbing

If you’re dealing with drain flies, which are a type of gnat, then it may be a sign that it’s time to call a plumber.

These types of gnats can indicate that you have a leak somewhere. These flies love to eat bacteria, sewage and gunk in drains and even garbage disposals.

Keep your drains clean by applying a foaming drain cleaner or flushing them with boiling hot water once a week.

Use Fly Paper

You can use fly paper for more than just trapping house flies – they’re great for catching gnats, too. 

There’s something oddly satisfying about watching the gnats fly right into the paper and get stuck on its sticky exterior. Once they’re stuck, they’ll be unable to escape and will eventually die. It’s a cruel way to die, but this is an effective, chemical-free way to get rid of gnats.

Try hanging ribbon fly paper in areas where there’s a lot of gnat traffic, or you can apply window fly paper which will cover an entire window in adhesive paper. 

Most people prefer to use the ribbon paper because you have more freedom with placement. Window adhesive may be the better option if you’re dealing with fungus gnats feeding on plants or produce near your kitchen window.

Try a Bug Zapper

Although bug zappers are designed for bigger bugs, like mosquitoes, they can also work for gnats if you get the right type. Small, compact models are best, and they work without you even having to lift a finger.

They now make zappers that are compact in size, safe for indoor use and have a discreet design. The great thing about these modern bug zappers is that they’re noiseless, so you won’t hear a “zap” every time it catches a gnat.

Pour a Glass of Wine

Gnats love fermented foods, so it makes sense that they’d have a taste for wine. Don’t use that expensive bottle that you’re saving for a special occasion. Use an expired bottle of wine that’s almost turned to vinegar to create your trap. 

You can use the wine in the same way that you’d use vinegar to catch gnats. 

  • Pour the stale wine into a small glass or vessel
  • Add a few drops of dish soap
  • Place the trap in gnat-infested areas of your home
  • Watch and wait as the gnats drop into the trap

The great thing about this gnat trap is that it’s free and it helps you get rid of that stale wine you forgot about in the back of the fridge. Just don’t leave it out too long, or the smell will start permeating your home.

Rotting Fruit Trap

The very thing that attracted the gnats can be used against them. 

  • Place a few pieces of overripe fruit in a bowl.
  • Cover with plastic wrap. 
  • Use a rubber band to keep the plastic wrap in place.
  • Using a toothpick, poke a few holes in the top of the plastic wrap.

The gnats will make their way to the fruit through the holes, but they won’t be able to reemerge.

How to Get Rid of Gnats in Plants

If you have a horde of fungus gnats in your home, you’ll want to focus on treating your plants.

First and foremost, you have to stop watering your plants. Overwatering is likely what’s causing these pesky bugs to show up in the first place. Overly wet soil is a breeding ground for fungus and mold, which is what attracts these fliers. Water holding and soil with peat moss are also attractants of fungus gnats.

Homemade Trap

You can use the homemade trap recipe above to kill the gnats in your plants. But instead of placing a lid on the jar, leave it open, and place the jar (or bowl) near your houseplants. The gnats will be attracted to the vinegar, and die in the jar or bowl.

Insecticidal Soap

Another great way to get rid of these pests is to use an insecticidal soap spray, and spray the soil daily or every other day.

You can purchase commercial-grade versions of these soaps in most garden or home improvement stores. But you can also make your own homemade version. While this version does not contain any of the insecticides you’re used to, it will kill the gnats in your plants.

Mix together:

  • Castile soap
  • Water

Dish soap will not have the same effect as castile soap, so do make sure that you use castile soap. The fatty acids in this soap dissolve bugs, which is why it’s so effective. Dr. Bronner’s is a great brand of castile soap. It’s gentle and natural.

This mixture is more than just a gnat spray. You can use it to kill other pests as well – indoors and outdoors – including aphids, spider mites, mealybugs and more.

How to Get Rid of Drain Gnats

A bottle of ammonia with white-yellow tag on white background.

If you have the unfortunate displeasure of dealing with drain gnats, there’s a simple and easy way to get rid of these pests:

  • Ammonia

Pouring a small amount of ammonia down the drain will kill any gnats that are living in there.

Note: If you use ammonia in your drains, allow it to dilute for several hours before using the sink again.

Not too keen on the idea of pouring ammonia down the drain? Here’s an alternative:

  • Baking soda
  • Vinegar

First, pour the baking soda into the drain. Next, pour a cup of white vinegar down the drain. The baking soda and vinegar will cause a reaction – you should hear a lot of fizzing and you should see bubbles. Allow this mixture to sit for a few hours, and then pour a pot of boiling water down the drain.

Both ammonia and the baking soda mixture will clean out your pipes. So, you’ll kill gnats and have squeaky clean drains.

Read more about Get Rid of Drain Gnats

How to Get Rid of Gnats Outside

What if the problem isn’t inside your home, but outside? It’s hard to enjoy time out in the yard if you’re swarmed with gnats the moment you walk outside.

We’ll show you how to catch gnats, and what to do to repel them.

Keep Your Yard Clean and Tidy

One of the best ways to keep gnats out of your outdoor space is to keep it clean and tidy. Ensuring that your garden is free of fungus and mold is the first step.

  • Check areas that are shady and have poor circulation first. Look for rotting plant debris, and remove it immediately. Flying gnats are attracted to rotting organic matter.
  • Make sure your compost pile is far from your home if you have one.
  • Trash cans should be covered at all times, and make sure that you clean up any plant debris you find.
  • Improve soil drainage to keep your plants from holding water.
  • Avoid overwatering your plants.
  • Check for standing water in drainage areas and gutters.

If you have an infestation of gnats, the above steps will help keep the population under control. But you can also take steps to get rid of these insects in the meantime.

Outdoor Gnat Traps

The indoor trap we made with vinegar can also work outdoors. Just make sure that you place the jar where the gnats are spending most of their time. You may need to make several traps to catch them all.

You may also try sticky traps. Gnats are attracted to the color yellow, and you can find yellow sticky traps in home improvement stores or online.

There are also electronic devices that are used to repel gnats. While these aren’t technically traps, they will send these bugs running for the hills, which is just as good (and possibly more humane).

How to Make Gnats Repellent

When it comes to repelling gnats, all the usual suspects will work perfectly, and that includes:

  • DEET
  • Citronella
  • Pine oil
  • Vanilla

You make an effective homemade bug spray with citronella and cedarwood essential oils, vanilla extract, and water.

How to Prevent Gnats

Once you’ve gotten rid of those pesky gnats, you probably want to keep them from coming back. Prevention is the best way to keep these flies away.

Here are some tips to prevent future gnat infestations.

Cover Trash Bags

Trade in your open kitchen trash can for a closed version. And make sure that the lid on the trash is tightly sealed. 

An open trash bag is an open invitation to gnats because the trash odor spreads throughout the house. 

As for your outdoor trash, make sure that all bags are tied tightly and placed in tightly-sealed cans. This will also help prevent other pest and rodent infestations, like ants, roaches, flies, rats and raccoons.

Don’t Leave Dirty Dishes in the Sink

Clean dirty dishes right away either by hand or by loading them into the dishwasher. 

Those tiny bits of food left on your plate and cookware can attract and feed gnats. Make sure that you scrape off those bits of food into the trash can and rinse your dishes before loading them into the dishwasher.

Place leftover food in a tightly-sealed container and store it in the fridge or pantry. 

Change Poor-Quality Soil

Poor-quality soil can attract fungus gnats. If you notice that most of these pesky flies are concentrated near your plants (indoors or outdoors), it may be time to change the soil.

Once you’ve changed the soil, take care not to overwater your plants, which will only attract more gnats.

Eliminate Damp Areas

Gnats and other pests thrive in areas that are moist, dark and damp. Drain flies in particular are known to populate in areas where there are plumbing leaks.

Check the drains and sinks in your kitchen and bathrooms for potential leaks. You can also use a dehumidifier to reduce dampness in bathrooms and other areas of your home.

Outdoors, remove any free-standing water and debris that may create the damp, moist environment gnats love.

Perform Preventative Maintenance

Along with all of the tips above, you should also perform preventative maintenance on your home to prevent all types of pests, including gnats, from making your life miserable.

Start by sealing any cracks and small openings around doors and windows as well as your foundation. Even the tiniest of gaps can provide can provide entry to gnats.

Make sure all screens are in good working condition. Repair and replace as needed.

Repair any leaks near sinks and indoor pipes that may be contributing to your gnat problem. Apply a bleach solution to surrounding areas to prevent mold growth.

To keep your drains clean, pour two tablespoons of baking soda into the drain and then pour a cup of white vinegar. The vinegar will cause a bubbling, foaming reaction that helps remove gunk and grime in your drains. Let the solution sit for about two hours, and then pour a pot of boiling water down the drain. 

You should also use a long-handled cleaning brush to remove gunk and organic matter from your drains. And from now on, you should probably plug up your drains when they’re not in use. This will ensure that the flies stay trapped in the drain and are unable to access your home.

Another important thing: never pour oils down your drains. Doing so can damage your pipes, cause plumbing problems and also feed the gnats. The fat and organic matter in oils is the perfect food for these pests. 

Instead of pouring it down the drain, either recycle the oil or pour into an empty milk or food container and toss it in the trash. 

For outdoor prevention, start by cleaning your gutters. This is a great way to stop a gnat problem before it even starts. Your home’s gutters collect dirt, leaves and other debris which gnats love. It’s a moist, damp environment that can easily turn into a breeding ground for these pests. Take the time to clean out your gutters at least twice per year.

A little preventative maintenance can go a long way in avoiding a gnat problem. Just make sure that you’re consistent in your efforts of keeping a clean, tidy home – inside and out.

Gnat Control FAQs

What Does a Gnat Look Like?

A quick glance at pictures of gnats will help you differentiate a gnat from a fruit fly. The main characteristics of a gnat are:

  • Glossy and black (eye gnat)
  • Deep gray or black (fungus gnats, a.k.a. soil gnats)
  • Red or orange (red gnats)

Eye gnats are 1/16” in size, while other gnats are 1/8” in size. There are also Savannah sand gnats, black flies or buffalo gnats, all of which look rather similar.

Where Do Gnats Come From?

Fungus gnats are the most common gnat found around the home, and they lay eggs, which lead to their population growth. These pests lay eggs and within as quickly as four days, these eggs can hatch into larvae – it’s that quick.

Within just a week, the pupal stage will be over, and the gnat will be in the adult stage.

Will Gnats Go Away on Their Own?

In some ways, yes. Gnats will technically go away on their own, but you’ll be battling these flies for a few weeks before they finally disappear. And you may just make the problem worse if you bring home new fruit or produce that you just leave out on the counter.

Of course, they’ll only go away on their own if you remove their food source and keep a tidy home. Taking out the trash regularly and making sure that you keep dirty dishes out of the sink will help get rid of the gnats faster.

If you don’t do anything at all, meaning that you don’t remove the rotting food or keep a tidy home, the gnats will never go away. In fact, the infestation will only get worse. Eventually, you may wind up having to hire an exterminator. 

Because these flies can lay so many eggs in their lifetime, you could potentially be dealing with a major swarm of gnats that are not only pesky, but also a health hazard.

At What Temperature Do Gnats Die?

Gnats cannot live in cold temperatures. They love warm and damp environments. They prefer to live in climates where temperatures range from 75-80 degrees.

Any hotter or colder than these temperatures could make your home inhospitable to gnats.

Leave a Comment