How to Kill Gnats

Gnats are tiny flying insects that can be hard to see when alone. They can easily be seen when in swarms or biting you. sandra standbridge / Getty Images

Gnats are tiny flying insects that can be hard to see when alone, but not when they're in swarms or biting you. Gnats can infest homes and gardens and are hard to get rid of or manage.

Here's how to kill gnats:


  • Gnats are attracted to rotten or wet areas. Minimizing the amount of accumulated garbage and rotting material in and around your home will minimize your chances for attracting gnats. Eliminate their food supply, and they'll die.
  • Gnats like to feed on fungus and organic matter in soil. Avoid over-watering your garden and lawn. If you keep potted plants in your house, allow the soil to dry. Gnat larvae can't survive in dry soil.
  • Gnats can be killed with aerosol insecticides. Chemicals like pyrethrins, resmethrin, tetramethrin, and d-trans allethrin will kill any gnats they contact. Avoid spraying food or plants directly with these chemicals. Spray the insecticides every seven days for five weeks to get rid of the gnats for good. Gnats usually only live for a month, so if you don't miss any applications you should get them all.
  • Gnats are attracted to bright lights and colors. Changing your outdoor lights from white or yellow bulbs to orange sodium lights should keep gnats away.
  • Gnats can be zapped with electric bug zappers. Although they won't get rid of all of them, these devices will kill a lot of gnats, and help keep their population down while you attack them in other ways.
  • Gnats are attracted to bright colors. Therefore, brightly colored bug traps will kill some of your gnats. Use bright insect strips or make your own with by putting sticky oil on brightly painted cardboard. Hang the traps out in the open to attract the gnats [source: Drees, PestControlCanada, Get-rid-of-pests].