How to Get Rid Of Fungus Gnats in Plants (Indoors & Outside)

​I always check in with my email list to see what their biggest pain point is when it comes to growing veggies. Asking how to get rid of fungus gnats is always at the top of the list!

And, just so we’re on the same page:

Fungus gnats are those tiny, black flies that get everywhere. If you have houseplants or take care of plants outside, chances are that you’ve seen them.

fungus gnats
Fungus Gnats

​These fungus gnats crawl on top of soil, hover around leaves and get in your face. Truly, an annoying species.


The adults don’t cause any particular harm to plants, but they do lay eggs. And, that’s where the problem ​starts.

It’s the fungus gnat eggs and subsequent larvae that cause the most problems.

After the eggs hatch, the fungus gnat larvae feeds on plant roots. These larvae have ​worm-like bodies with dark heads.

Fungus gnat larvae
Fungus Gnat Larvae

​​Larvae can stunt plant growth, particularly ​​in younger seedlings.

By now, you’re probably ready for the methods that kill fungus gnats.

Don’t worry.

This article not only covers how to get rid of gnats inside the house, but you’ll learn solutions for getting rid of gnats in plants and outside. (By the way, these are all organic methods.)

But wait; there’s more. 🙂

You’ll also learn how to prevent the fungus gnat eggs from even hatching! I start a lot of plants indoors, and the DIY fungus gnat neem oil spray (below) has saved me tons of aggravation.

Where Do Fungus Gnats Come From?

Gnat eggs and pupae can reside in the mixes we use to start our seeds and grow our plants. They love that moist, organic media.

A generation of fungus gnats can be produced in about 17 days. [source] This number may vary, depending on temperature (eggs hatch in 3 days at 75 degrees Fahrenheit).

​How To Test For Fungus Gnat Larvae With A Potato

​If you want to confirm that you have fungus gnat larvae in your potting mix, use slices of potato. ​Larvae are attracted to potatoes​, and they’ll leave the soil to feed on it. ​

  1. Slice a potato into thin slices and leave them on top of the soil line.
  2. Wait 2 to 3 days.
  3. Check your potato slices for larvae. They look like tiny, moving seeds with black heads.
  4. Throw the infested potato slices away.

​​If you discover larvae, use the prevention and control methods​ below to get rid of them.


​How To Get Rid Of Fungus Gnats Inside The House

​​A fungus gnat’s life cycle is brief, and many generations can occur within a short window. Consequently, this is why you can have an infestation very quickly.

Further, fungus gnats spend about 10 days in the larvae and pupae stage (when root damage ​happens). That’s why ​you want to start getting rid of them immediately.

You can use the prevention method below before and after your chillies (or other types of plants) germinate.

Disclosure: Some of the links on this page are affiliate links, which means I earn a small commission if you ​make a purchase using my links. This is at not additional cost to you. The products are only recommended because I personally use them and find them helpful.

Fungus Gnats Neem Oil Spray (Organic)

  1. ​Pour a quart of water in a spray bottle.
  2. Add a TSP of neem oil with Azadirachtin. Azadirachtin is the most active ingredient in neem for killing pests.
  3. Squeeze a few drops of dish soap. Add a couple drops of peppermint oil too, if you have it. (Pests don’t like the smell of peppermint.)
  4. Shake up your bottle to mix the ingredients.

​If Your Seeds Haven’t Germinated Yet

​(Did you know you can kill fungus gnats​ before your seeds even sprout? I learned ​how to do this by watching The Rusted Garden video underneath these steps.)

  1. ​Move your containers away from the grow lamp (if applicable) so you don’t inadvertently spray your lights and dull them.
  2. Spray ​the tops and bottoms of your containers, as well as the plant trays. Really soak these areas so beads of water sit on the top of the surfaces where fungus gnats can potentially be.
  3. Repeat the spray process every 3 to 4 days over a 10 day period. This ​ensures you apply this treatment over ​the time​ frame when fungus gnat larvae is likely to hatch and emerge.

(Gary from The Rusted Garden also says you can hydrate your starting mix with boiling water, as eggs seem to be in all starting mixes.)

If Your Seeds Have Germinated

  1. ​​​Wait until your grow light turns off for the night (if applicable). (I don’t recommend spraying anything on seedlings while they’ll be in the light because they can potentially burn.)
  2. Spray a small area of your seedlings and wait 48 hours to ensure they don’t have a bad reaction.
  3. Spray the container tops and bottoms, plant tray and tops and undersides of your seedling leaves.
  4. Repeat the spray process every 3 to 4 days over a 10 day period.

» Related: How to Care for Pepper Seedlings after Seeds Sprout

Still Seeing Adult Fungus Gnats Indoors?

Here are a couple of solutions:

  1. ​Use yellow sticky traps (Amazon link). These traps will capture the adults and prevent them from breeding.​ (I don’t use these outside because they have the potential to ​kill beneficial insects.)
  2. Point a small fan ​away from your plants. ​Gnats are small and can be blown away by the air flow.

(​For your reference, I’ll link all the products I mention in this post down below.)

​How To Get Rid Of Fungus Gnats Outside

Here are a couple of ways to get rid of fungus gnats in plants that are outdoors.

Make Fungus Gnat Traps

  1. ​Fill a shallow container with a little bit of apple cider vinegar. (I used ​the scoop from my protein shake and added ~ 1 TBSP of the vinegar.)
  2. ​Add a couple drops of peppermint oil. (Optional)​​​
  3. Add a couple drops of dish soap.
  4. Mix the liquid and leave your container near the plants where you​ see the fungus gnat activity. Be sure to replace the trap solution, as necessary, until the gnats are gone.

​​Here’s an image of my trap. I left​ a bunch of these next to the pepper plants in my EarthBox. ​​​I started seeing results in a couple of days.

fungus gnat trap near pepper plants

Spray An Organic Neem Oil Spray

  1. Make a batch of neem oil spray.
  2. Wait till the sun goes down, and then spray a small, leafy area of your plants as a test. ​After 48 hours, check to make sure your plant doesn’t have damage. (It shouldn’t, this is just a precaution).
  3. ​Wait till the sun goes down. Spray the leaves, stems and tops of the soil.
  4. ​Continue to spray every ​3 days for about a week or more. Keep in mind, adult gnats can hang around for 7 to 10 days, so you’ll want to spray just as long to ensure you kill all the gnats during this time span.

About Neem Oil and Azadirachtin

​Recently, I discovered that there are different types of neem oil. (Neem is a naturally occurring pesticide derived from seeds of the neem tree.)

​The ​best neem is one that is “cold-pressed” ​​and has “Azadirachtin” as it’s main ingredient. Azadirachtin is the most active component for killing pests.

​Azadirachtin ​acts as a pest repellent in that it interferes with the pest’s hormone system so that it loses the desire to eat. The pest never gets to mature or lay eggs, and it eventually dies.

Many commercial neem products are processed in a way that actually removes the Azadirachtin. What you’re left with is typically a “clarified hydrophobic extract of neem oil.”

​This type of neem can eliminate pests on contact, ​but it’s not as effective because you won’t get the repellent benefits of Azadirachtin.​ ​Despite this huge difference, all products are still labeled as “neem oil.”

​(I’ll link a ​cold-pressed neem with Azadirachtin product below, ​as an example.)

How To Get Rid Of Gnats In Plants

​You can use biological measures separately or together, depending on your preference.

​Bti For Fungus Gnats

Bacillus thuringiensis subspecies israelensis is known as “Bti.” Now, Bti is not the same as Bt.

Bti specifically treats insects, such as fungus gnats and mosquitoes, while Bt manages bugs like worms and caterpillars.

Bti is usually found in nurseries or home improvement stores. It’s a naturally occurring bacteria that I use in my organic garden if I’ve confirmed that larvae are present.

Bti is toxic to fungus gnat larvae, so they’ll die before they have a chance to hatch. Common Bti products are Mosquito Bits, Mosquito Dunks and Gnatrol.

Gardeners may use Bti in different ways. Generally, you add the product to water, let it dissolve and then water your plants with it. My preference, for example, is to let a mosquito dunk dissolve in 5-gallons of water, fill a watering can and then apply it to the container’s water reservoir.

Bti products need to be continuously reapplied to be effective (generally every 14 to 30 days). Keep in mind it may take several days to see results.

Nematodes For Fungus Gnats

​Steinernema feltiae is ​known as a “parasitic nematode” ​or “beneficial nematode.” It’s particularly effective when ​temperatures range from 60 to 90 degrees Fahrenheit and conditions are moist.

​Once applied to the soil, these nematodes go to work by ​seeking out larval and pupal insects (in this case fungus gnats) and feeding on them. They destroy them from the inside out and move on, all the way reproducing in numbers. 

The benefit of using nematodes is that once established, they provide season-long control.

(Beneficial nematodes are typically available via mail order ​from ​special suppliers. I haven’t found one to recommend yet, but will update this post once I do. If you have a good beneficial nematode source, please share in the comments below!)

By the way… If you’re looking for organic ways to keep your pepper plants safe, be sure to check out The Chile Plant Hospital. This ebook helps you diagnose and treat common problems, such as insects and deficiencies, so you can fix things before they get out of hand.

​​Best Practices For Preventing Fungus Gnats

Here are more tips to keep in mind as you take care of your plants.

Reducing Moisture 

  • ​Don’t overwater your plants
  • Provide good drainage (you can add more perlite or sand to your potting mix.)
  • Allow the ​top of your container ​mix to dry between waterings
  • Clean up any standing water or fix leaks.

​Removing Organic Matter

  • ​Clean up ​nearby organic debris so fungus gnats don’t start feeding or breeding in it.
  • Do not use organic matter that isn’t completely composted. Unless pasteurized, the matter can potentially be infested with gnats.

Managing Infested Plants

  • ​Keep any affected plants away from​ everything else. Fungus gnats spread quick! (I know from experience.)
  • Potentially get rid of infested plants. Sometimes that’s the best option when things get out of control.

​​Products Mentioned In This Post

​​Here’s an Amazon page that shows all the products I use in the​ steps. (See “Pest & Disease Supplies” box.)

​​In summary, I hope this information helps you get rid of fungus gnats. These solutions, along with this pest and disease control article, will help you effectively manage garden pests. ​

More Posts On Growing Peppers In Containers:

And for those of you looking for more information on dealing with plant pests and disease… Make sure to check out The Chile Plant Hospital. You’ll discover some of the most common issues that affect chillies, and get the exact remedies you need to fix each problem fast. I’m always here to answer questions!

Leave a Comment