How to get rid of fruit flies
how to get rid of fruit flies are small, irritating insects that often swarm around garbage, vegetables and fruits. Chances are you might have even spotted them in drains, too. If you’re not careful, the problem can easily get out of control, because female fruit flies can quickly lay hundreds of eggs on overripe produce. This may even result in maggots and other bugs setting up shop in your kitchen and dining area.
The experts we interviewed recommended a slew of effective homemade traps, including ones that rely on apple cider vinegar, rubbing alcohol or old wine and beer. Or, you can lure them into a jar filled with a combination of dish soap and vinegar. Just keep in mind that while some of these traps work their magic instantly, others perform overnight.
The key is acting fast to get a handle on your fruit fly infestation, then taking the necessary steps to keep them away from your home for good. (For that, you’ll need to get into a routine of cleaning your garbage can frequently, washing any produce you buy right away and tossing overripe fruit.) But rest assured that soon enough, you’ll be able to say goodbye to these sugar-loving pests forever.

What are fruit flies?
If you spot tiny brown bugs with red eyes flying around your kitchen, they might just be fruit flies (Drosophila melanogaster). But first, be sure you’re identifying them correctly — they could also be drain flies, house flies or fungus gnats (which favor overwatered houseplants). For those bugs, see our guides on how to get rid of gnats and how to make a homemade fly trap.
What causes fruit fly infestations indoors?
how to get rid of fruit flies. According to the pros at Orkin, fruit and produce that’s ripe, rotting or decayed, along with fermented goods like beer, liquor and wine, can all attract fruit flies. And if there’s enough food, you can likely find them hovering around trash cans and garbage disposals. Don’t surprised if you suddenly notice a couple tiny fruit flies turn into a full-blown infestation in the blink of an eye.

How to prevent fruit fly infestations
Start by deep cleaning your kitchen and throwing out any rotten food. To cut fruit flies off from their food source and prevent them from entering your home in the first place, take these preventive measures:
- Regularly toss any overripe produce.
- When possible, store fruits and veggies in the fridge.
- Wash produce as soon as you get home to remove any existing eggs or larvae.
- Take out the garbage regularly.
- Clean up spills ASAP, especially fruit juice or alcohol.
But first, you’ll want to find a way to trap the existing fruit flies in your kitchen, fast. Our Good Housekeeping Institute Cleaning Lab experts have found that a DIY fruit fly trap is a quick and effective solution. What’s more, these homemade fruit fly traps can be fashioned from supplies you likely already have in your pantry. If you want to skip the DIY approach, you can buy pre-made fruit fly traps, too, including the GH Seal-backed Zevo Flying Insect Trap, which was vetted for performance and effectiveness by our on-staff chemists in the GH Institute.
1. Find the source
The first thing you need do is figure out where the flies are coming from. If they’re hanging out around any open food items, throw the food out and scrub the area clean. You can use any type of cleaner to disinfect the area. In some cases, removing their “home” can be enough to drive the fruit flies away.
2. Clean common areas
After you’ve found the source of the problem, check out the drain in your kitchen sink. If it’s clogged or in need of a good cleaning, now’s the time to take care of it. Fruit flies like to live and breed in warm, damp spaces.
Don’t forget to check your trash cans for any signs of fruit fly activity. Fruit flies have been known to lay their eggs in trash cans, worsening the infestation.
If they’re swarming around your trash can or if you’d like to prevent such a situation, take out the trash and wipe down the can using a heavy duty cleaner such as bleach. Make sure the cans are completely dry before using them again.
3. Use the rotten fruit against them
If you still spot fruit flies hanging around, you can set a trap using things that you may already have in your kitchen. This includes any rotten or open food that attracts fruit flies. Follow these steps:
- Instead of tossing out the rotten or open food, put the food in a disposable container.
- Cover the container with plastic wrap.
- Poke a few holes in the wrap, place it where fruit flies congregate, and wait.
The flies should swarm to the inside of the trap. You can then dispose of them how you see fit. Repeat this process until all of the fruit flies are gone.
4. Make a swimming pool trap
Have leftover red wine that you don’t plan on finishing? Use it to create a swimming pool trap for the fruit flies. Here’s how:
- Pour some red wine and dish detergent into a disposable container and stir.
- Cover the container with plastic wrap.
- Poke small holes in the plastic wrap. Make sure the holes are big enough for the fruit flies to get in.
The wine should attract the fruit flies, and the combination of wine and dish detergent will make it difficult for trapped flies to fly and will drown them. You can repeat this process until you no longer see any more fruit flies.
5. Mix a vinegar solution
You can also try to attract fruit flies by making a vinegar trap. Here’s how:
- Fill a disposable container up with water.
- Add a few tablespoons of vinegar and sugar to the water and stir.
- Add a few drop of dish soap to the solution and stir.
After mixing your solution, place the container wherever the fruit flies congregate. They should be attracted to this solution and will drown once they touch the water. Continue this method until you no longer see any fruit flies.
6. Try a store-bought trap
If homemade traps aren’t working for you, visit your local hardware store and purchase a sticky fly trap. These traps work on common flies and fruit flies.
Place the trap in the problem area and dispose of it once the sticky area is full. You can replace the trap as necessary.
7. Hire an exterminator
Hiring an exterminator should be your last resort. Although this is usually effective, it can be costly. You or your pets may also experience adverse reactions to the chemicals used to get rid of the fruit flies.
If the fruit flies return after your house has been treated, the company may treat your home again for a free or reduced rate.
Can a fruit fly infestation affect my health?
If left untreated, a fruit fly infestation can pose potential health risks. Fruit flies are known to fly around and pick up bacteria that they then deposit onto fresh foods.
They’re particularly drawn to manure and other feces that can contain bacteria such as E. coli. They then carry the bacteria with them.
Additionally, after mating, female fruit flies inject batches of eggs into fresh fruit. This contaminates the fruit.
How to make a fruit fly trap
Ingredients
- 4 tablespoons apple cider vinegar
- 4 tablespoons warm water
- 1 teaspoon dishwashing detergent
Method
Step 1: Add the vinegar and water to a small bowl and squeeze in the dishwashing detergent.
Step 2: Leave in the area where you get most fruit flies, eg. near the fruit bowl.
You’ll see the flies gradually collect in the bowl. Change the mixture at least once a day.
Other ways to reduce fruit flies in your kitchen
There are a few other ways to sort out the punishing fruit fly infestation in your home, aside from the game-changing apple cider vinegar hack.
- Regularly spray and wipe your bench top. The sweet residue that is sometimes left behind after cooking and cutting is what attracts fruit flies, so make sure it’s super clean!
- Clean your drain and sink! If you have food lingering in your sink, this might be the reason for your unwanted friends.
- Empty your rubbish bin often. Any scraps that hang around for too long are the perfect home for those pesky guests.
- Remove fruit that spoils easily from your fruit bowl. Bananas go brown in the fridge and you don’t want fruit flies to find their way into your pantry, so I peeled and halved all my bananas, popped them into a sandwich bag and into the freezer. They were then ready for me to use in smoothies and baking (they keep like this for ages!)
Here are five FAQs on how to get rid of fruit flies: