How to Get Rid of Fruit Flies
Give fruit flies the boot with a homemade solution known as the fruit fly magnet.
When I was a little girl, I imagined that fruit flies hung out at the top of the telephone pole near our house, scoping out neighborhood grocery runs. When someone brought home bananas or peaches, the fruit flies assumed attack formation and arrived in a squadron to feast on the fresh fruit.

Julie Martens Forney
Turns out, my imagination wasn’t too far off. With a poppy seed-size brain, fruit flies can smell their way to fermented fruit from as far as three-quarters of a mile away. As you bring home farmers’ market finds, CSA share or fresh-picked tomatoes from the patio, chances are a fruit fly has already honed in on the haul and is winging its way to your kitchen counter.
What’s the right choice when fruit flies show up by the dozen? Whip up a batch of fruit fly magnet, a quick blend that lures these winged pests to a buffet they can’t resist—and can’t escape. The ingredients are likely already in your cupboard: sugar, vinegar and dish soap.

Julie Martens Forney
Use 1.5 tablespoons each of vinegar (apple cider or white) and sugar. Add a small amount of warm water, stirring to dissolve sugar. Complete the mix with a few squirts of dish soap and enough water to make 8 to 16 ounces of mixture. How much water to add depends on what you use to hold the blend—and this is where your success hinges.
How It Works
Researchers have discovered that fruit flies track potential food sources by both odor and shape. In particular, they’re looking for roundish shapes that resemble fruit. Displaying your fruit fly magnet in a round bowl or tea cup enhances the odds you’ll catch more fruit flies. I like to use my great-grandmother’s Fiestaware tea cups. There’s no scientific data (yet!) supporting the idea that color plays a role in how a fruit fly finds its meal. All I can share is that when I use the yellow and orange cups, I catch more fruit flies than when I use blue or green.
Why This Blend Snares Fruit Flies
- First, it reeks of the odor that’s irresistible to fruit flies.
- Second, the soap cuts the surface tension of the solution, which means once fruit flies land, they sink.
Use Tips
- Let the solution sit out for up to 14 days, adding water as needed to replace any that evaporates.
- Place it near ripening fruit on the kitchen counter.
- For a massive outbreak—the kind that occurs in autumn when fruit trees are heavy with ripe fruit—fill large serving bowls with the mixture to provide a larger surface area to catch more fruit flies.