Flies are common household nuisances that spread illness by contaminating food and various other surfaces. Some flies, like deer and horse flies, even bite! Show them whose home it is by using a variety of traps, repellants, and chemical sprays. As you eliminate flies, find ways to prevent them from coming in your home by cleaning up trash and other sources of infestation. By using these treatments consistently, you can make your home less appealing to flies as a source of food and shelter.

Method 1
Method 1 of 3:

Trapping and Catching Flies

  1. 1
    Use a vacuum for a quick way to catch flies in a room. Flies are very hard to catch with a regular flyswatter, but you can easily trap them with a vacuum. Put a hose attachment on your vacuum, point it at a fly, and watch it get sucked up. It's simple to use and stops you from having to run around all day trying to swat these quick pests.[1]
    • If you don't have a good vacuum, you could also get an electrified fly swatter. It is way more effective than a regular one and works outdoors as well. Once you get close to a fly, the electricity stuns it so you can get rid of it.
  2. 2
    Set out a dish soap trap if you need to lure out flies. Choose a shallow container with a wide opening, such as a small saucer or glass, so that those nasty flies go straight for the bait. Pour in at least 1 US tbsp (15 mL) of apple cider vinegar, then add about 3 drops of any liquid dish detergent. The soap breaks the surface tension so the flies can't get out once they fall in. The vinegar is the bait, and the apple cider scent attracts plenty of flies.[2]
    • If you don't have apple cider vinegar handy, make sure you have a fruit-flavored dish soap. Replace the vinegar with an equal amount of water.
    Advertisement
  3. 3
    Create a funnel trap to prevent smaller flies from escaping. House flies and fruit flies can't resist a sweet treat. After adding at least 13  c (79 mL) of water into a mason jar or a tall glass, mix in 1 US tsp, or about 4 g, of sugar. Set a plastic funnel on top of the jar. Then, watch as your unwanted house guests crawl in without being able to get out.[3]
    • Sugary foods and drinks make for great bait if you don't have sugar. Try using honey, wine, or even some decaying fruit. You could also add yeast to help bring in the flies.
    • To make your own funnel, cut a piece of paper into a circle, then cut a wedge out of one side. Fold the cut ends together to create a cone with about a 0.39 in (0.99 cm) bottom opening. Tape the ends together to hold the cone in place.
    • Another way to make a cone is by cutting a soda bottle in half. Put the bait in the bottom portion. Remove the cap from the top portion, turn it upside down, and insert it into the bottom portion.
  4. 4
    Hang flypaper if you need to prevent flies from landing. Flypaper comes in strips you hang from exposed areas where flies land, such as around fans and door frames. Once the flies get tired, they land on the first spot they see. A caught fly also attracts other flies, so sit back and relax as you wait.[4]
    • These strips are very sticky, so be careful to avoid getting them stuck to your hair. Try to keep the strips in visible areas as much as possible.
    • Remove the flypaper as the flies accumulate. It is a little gross to look at, but it's a small price to pay for a fly-free home. You can then hang up a new strip to catch more flies.
  5. 5
    Install a fly zapper for a reusable trap that kills flies. You will need a free electrical outlet available to plug in the zapper. Once you hang it up in your home, let its light attract nearby flies. The flies drop into a plate on the bottom that you can slide out and clean off. It's kind of fun to hear the loud zap when you're not even breaking a sweat.[5]
    • Electric zappers produce a loud noise when flies land on them. If you're not prepared for it, it may be a little annoying.
    • There are some zappers that work well outdoors, which the manufacturer will list on the packaging. These zappers work best when you're nearby. When you don't need them, take them down so they can't attract more flies.
    • You could also get a UV light trap. UV traps are quieter than regular electronic traps. The flies land on glued boards you can remove and replace as needed.
  6. Advertisement
Method 2
Method 2 of 3:

Repelling and Poisoning Flies

  1. 1
    Mix water and cayenne pepper into a natural spray repellant. Flies, along with many other bugs, can't stand the heat and will avoid spices. Add 1 cup (240 mL) of water to a misting bottle, then mix about 1 US tsp, or about 1.80 g, of cayenne pepper into it. Add the water to areas like doorways and window sills to keep your home free of pesky invaders.[6]
    • You could chop or grind up fresh cayenne or use dried powder to make the repellant. Dried cayenne is stronger and more effective, but it loses potency faster. Spray more of the repellant when you can no longer smell it in the air.
    • Ginger is another strong spice that repels flies. Use it when you don't have any cayenne powder lying around.
  2. 2
    Grow scented plants like basil near openings to your home. For a natural way to drive away flies that you can also use in your cooking, look no further than scented plants. Herbs like lavender, lemongrass, and mint are only a few of the options available. Set up your new garden near places where flies tend to gather, such as near doors, windows, fruit gardens, and areas with standing water. Also, keep them around areas you go to when you're enjoying the weather.[7]
    • To plant herbs, use neutral soil or potting soil. You could keep the herbs in small growing boxes, pots, or in the ground. Make sure the soil is well-drained and receives about 6 hours of sunlight each day.
    • These plants are non-toxic, so you don't have to worry about planting them. You could even keep small boxes of herbs on your window sills to deter flies.
  3. 3
    Stuff herbs into sacks to protect your pantry. Purchase some small sachets, or perfume bags, then fill them with your favorite herb. Clove is a good choice, but alternatives like basil and lemongrass work just as well. Then, set the sack in an area you wish to protect, like your snack cabinet. It works best in enclosed areas without a breeze to weaken the scent.[8]
    • Replace the herbs as they start to lose potency. When you no longer smell the herbs, throw them away and refill the bags.
  4. 4
    Blow away outdoor flies with a strong fan. That little fly bothering you won't be able to stand the force of your mighty fan. If you're having a party, for instance, position fans around your guests and the food table. As much as the flies try to reach you, they won't be able to keep their balance in the air.[9]
    • This works indoors as well. Try it by turning on a ceiling fan near where flies gather. The only problem is that it disperses the flies instead of getting rid of them, so use a trap or vacuum cleaner to catch them.
  5. 5
    Use a chemical fly spray to deal with serious infestations. Chemical fly sprays are quick and effective, but they are also pretty toxic to people and pets. For the best result, get a spray with Pyrethrum in it and mist any areas where flies tend to gather. Protect yourself by putting on a respirator mask before using the spray. You may need to repeat this process for up to 2 weeks in order to fully clean out an area.
    • Since sprays are pretty harsh, clear the treatment area. Keep other people and pets away for several hours as you air out the area.
    • If you're treating small groups of flies that are easy to handle, consider making your own trap first. Fruit flies, for instance, are fairly easy to handle with a sugary liquid and a little patience.
  6. Advertisement
Method 3
Method 3 of 3:

Cleaning and Securing Your Home

  1. 1
    Seal trash in a garbage bag and place a lid on the can. Garbage is the number one food source for flies, but keeping your home trash-free is never as easy as it sounds. Throw away trash as soon as possible, storing it in a trash bag placed in a sealed garbage can. That will show the flies that they can't mess with you![10]
    • Understand what types of food attract different types of flies. For instance, fungus gnats come from overwatered plants, fruit flies come from overripe fruit or produce, phorid flies come from trash and organic matter, and house flies come from standing trash or outside.[11]
    • To make your trash area more secure, use liners to keep cans and dumpsters clean. Empty them as they get full and wash them out whenever you notice spills.
    • When you clean out a trash can or dumpster, also check the area around it for spilled food. Sometimes food falls on the ground and it isn't easy to spot. If you notice flies around a clean, closed can, chances are a hidden spill is the cause.
  2. 2
    Seal food in containers and throw it away when it spoils. That food is rightfully yours, so show those flies that they aren't welcome. Keep your food in sealed containers. Place the containers in your refrigerator or cupboards, depending on what you're storing. As the food begins to go bad, get rid of it as soon as possible so the flies don't have a chance to settle in.[12]
    • Look out for leftovers! Flies flock to sugary drinks and decaying foods. That also makes them good for traps, so take advantage of the opportunity!
  3. 3
    Clean up spills in your home when you notice them. Liquid spills are easy to spot and get with paper towels, but don't forget about solid foods. Many times, crumbs fall into hidden areas you can't easily access. Take the time to check underneath your stove, for instance, in case you dropped something from last night's meal. By cleaning up these spills right away, you take away lots of food sources before flies ever find them.[13]
    • Flies like wet areas with decaying food in it. Check inside drains, inside dishwashers, and underneath appliances for food and moisture. Clean these items out as often as you can to prevent them from becoming fly havens.
  4. 4
    Repair screens and seal any gaps in your home. To keep insect visitors out, find out how they get in. No matter how good your home looks on the outside, cracks will form in the walls and insulation. Search for these gaps by inspecting your home. Then, seal these areas with caulk, weather stripping, and screens.[14]
    • Regularly inspect the screens and windows around your home, and repair them if you notice that any are torn or missing.[15]
    • Pay the most attention to areas where walls meet. These spots are most likely to have gaps in them that need to be filled. Squeeze a bead of caulk into the gaps to close them off.
  5. 5
    Drain standing pools to remove water sources. Watch out for any puddles that form after a hard rain. Also, keep an eye on buckets, birdbaths, and other areas that collect water. Clean and dry these spots so the flies don't have water to drink.[16]
    • To drain soil, change its slope, aerate it, or mix sand into it. Also, keep your lawn mowed to reduce the amount of water beneath the grass blades.
    • Be aware of damp areas in your home, such as drains and leaky pipes. Clean and make repairs as needed to keep your home dry.
    • Agitate the water in birdbaths with a fountain. That will break the surface tension and not let them land and have a drink.
  6. 6
    Remove leaves and other waste close to your home. You might not anticipate flies living among something as simple as dead leaves, but they often do. It's best to clean up leaves, animal waste, and other potential food sources as soon as you get a chance. Maintaining your yard is an important part of keeping the flies at bay.[17]
    • Keep compost piles at least 20 ft (6.1 m) away from your home to discourage flies from coming inside.
  7. Advertisement

Expert Q&A
Did you know you can get expert answers for this article? Unlock expert answers by supporting wikiHow

  • Question
    How do you keep bugs from flying in windows?
    Joshua Bloom
    Joshua Bloom
    Pest Control Specialist
    Joshua Bloom is a Pest Control Specialist and the Vice President of Operations of Standard Pest Management, a pest control company based in New York City. He has over 20 years of experience in the pest control industry and specializes in commercial and large facility pest control management. Standard Pest Control also specializes in ant, bed bug, cockroach, fly, and rodent control. Joshua is licensed by the NYSDEC (New York State Department of Environmental Conservation) for termite control.
    Joshua Bloom
    Pest Control Specialist
    Expert Answer

    Support wikiHow by unlocking this expert answer.

    Install a window screen over the outside of your window. If you already have a screen, make sure it's in good repair. Fix the screen if it has any tears because bugs will fly through them.
  • Question
    What foods attract bugs?
    Joshua Bloom
    Joshua Bloom
    Pest Control Specialist
    Joshua Bloom is a Pest Control Specialist and the Vice President of Operations of Standard Pest Management, a pest control company based in New York City. He has over 20 years of experience in the pest control industry and specializes in commercial and large facility pest control management. Standard Pest Control also specializes in ant, bed bug, cockroach, fly, and rodent control. Joshua is licensed by the NYSDEC (New York State Department of Environmental Conservation) for termite control.
    Joshua Bloom
    Pest Control Specialist
    Expert Answer

    Support wikiHow by unlocking this expert answer.

    Pretty much any food left out will attract bugs. To keep your home bug-free, put up leftovers right away and toss old food immediately. Don't leave any food sitting out in your home.
  • Question
    What are some common mistakes people make when they're getting rid of flies?
    Joshua Bloom
    Joshua Bloom
    Pest Control Specialist
    Joshua Bloom is a Pest Control Specialist and the Vice President of Operations of Standard Pest Management, a pest control company based in New York City. He has over 20 years of experience in the pest control industry and specializes in commercial and large facility pest control management. Standard Pest Control also specializes in ant, bed bug, cockroach, fly, and rodent control. Joshua is licensed by the NYSDEC (New York State Department of Environmental Conservation) for termite control.
    Joshua Bloom
    Pest Control Specialist
    Expert Answer

    Support wikiHow by unlocking this expert answer.

    The biggest mistake is not identifying what kind of fly it is. Fungus gnats come from over-watered plants, fruit flies from overripe fruit or produce, phorid flies from trash and organic matter, moth/drain flies from drains, and house flies from standing trash or outside.
Advertisement

Warnings

  • Insecticides are toxic, so use them carefully. If you have to use a chemical spray, keep other people and pets away until you air out the area.
    ⧼thumbs_response⧽
Advertisement

Things You'll Need

Trapping and Catching Flies

  • Vacuum cleaner
  • Dish soap
  • Jar or bottle
  • Flypaper
  • Fly zapper (optional)
  • Apple cider vinegar (optional)
  • Fruit or a sugary liquid (optional)
  • Paper funnel (optional)

Repelling and Poisoning Flies

  • Misting bottle
  • Water
  • Planting soil
  • Planting boxes
  • Chemical fly spray (optional)
  • Cayenne pepper (optional)
  • Herbs like lavender, basil, and mint (optional)
  • Flowers like nasturtiums(optional)

Cleaning and Securing Your Home

  • Soap
  • Water
  • Cleaning rags
  • Vacuum cleaner
  • Covered trash cans
  • Trash bags
  • Caulk

About This Article

Joshua Bloom
Co-authored by:
Pest Control Specialist
This article was co-authored by Joshua Bloom. Joshua Bloom is a Pest Control Specialist and the Vice President of Operations of Standard Pest Management, a pest control company based in New York City. He has over 20 years of experience in the pest control industry and specializes in commercial and large facility pest control management. Standard Pest Control also specializes in ant, bed bug, cockroach, fly, and rodent control. Joshua is licensed by the NYSDEC (New York State Department of Environmental Conservation) for termite control. This article has been viewed 1,223,362 times.
18 votes - 91%
Co-authors: 22
Updated: January 8, 2023
Views: 1,223,362
Article SummaryX

An easy way to get rid of flies is with a homemade fly trap. Start by adding equal parts of water and liquid dish soap to a wide-mouthed jar. For the best results, use fruit-scented dish soap since it will attract more flies. You can also add a splash of apple cider vinegar to make the bait solution more attractive to the flies. When you’re finished, put the jar in a place where you want to catch the flies, such as the kitchen. The smell of the mixture in the jar will draw the flies to the liquid, where the dish soap will coat their legs and wings and prevent them from escaping. Check your fly trap daily, and dump out any flies that may have been caught. Refill the mixture in your fly trap as needed. To deter flies from returning to your home, make a spray repellent with a tablespoon of cayenne pepper and water. Spray the repellent on doorways, window sills, and cracks where flies might enter. To make your home less attractive to flies, remember to keep your trash can sealed with a lid, eat or throw away fruits and vegetables before they go bad, and make sure your window screens are free from holes. To learn how to use store-bought fly traps, keep reading the article!

Did this summary help you?
Advertisement