How to Get Rid of Fruit Flies

Illustration by Wendy Wahman
First, let us take a moment to appreciate all the humble fruit fly has done for science.
The very qualities that make this insect (Latin name Drosophila melanogaster) a nuisance in your kitchen have also made them invaluable in genetic research labs for more than a century. These bug-eyed rotten banana enthusiasts show up reliably, whether you want them or not. They generate fast, going from egg to reproducing adult in less than two weeks.
In his lab at Washington State University Vancouver, assistant professor Seth Rudman raises about five million fruit flies a year. “If you want to do genetic crosses or you need to go across generations, they’re really useful for those types of investigations and understanding how traits are inherited,” he says.
Fruit flies helped humans understand basic genetics. Today they’ve graduated to more complex issues. Rudman and his graduate students at WSU’s School of Biological Sciences use their insect cohort to study how populations adapt quickly in situations such as climate change. In 1947, NASA even made fruit flies the first living creatures intentionally sent into space.
However, none of these accomplishments make these insects any more welcome in your kitchen.
The common fruit fly, also known as the vinegar fly, doesn’t bite or carry viruses. They’re not a danger, but they are a giant nuisance. That nuisance quality ratchets up in summer, with its abundance of ripe fruit.
Where Do Fruit Flies Come From?
More than 4,000 species of fruit fly exist worldwide, but Drosophila melanogaster is the one hovering around your overripe fruit. These insects are tiny enough to enter homes through even a small opening, according to the Cleveland Clinic. Their eggs, minuscule and tough to see with the naked eye, can hitch a ride on a fruit’s surface (a quick wash can help rinse that risk away).
And once your produce reaches the overripe stage, the real battle begins. Fruit flies are attracted to “a moist film of fermenting material,” according to the University of Kentucky’s Department of Entomology. This also means they can breed in drains, garbage disposals, compost and trash bins, even empty bottles or cans.
A female might lay as many as 500 eggs in her lifetime (aka a little more than a month). “They’re fantastic at reproducing,” says Rudman.
How to Prevent Fruit Flies
No surprise, the most effective protection against fruit flies is not letting them hang out and breed in the first place. “You can make some pretty good progress by keeping screens on your windows and not leaving overly ripe fruit out,” says Rudman.
Rinse and dry produce as soon as you bring it home. Store fruits and vegetables in the refrigerator, when possible, and be vigilant about removing anything that’s tipping into overripe or rotting territory.
A clean kitchen is a dull place for a fruit fly. Rinse bottles and cans before they go into the recycling bin and clean up spills, especially anything sweet or fermented, like juice or wine or beer.
Oklahoma State University’s extension points out a few less visible kitchen culprits that may need clean-up attention, like food that has accumulated “in corners, under counters, under baseboards, in the cracks of or around drain boards, in cracks around sinks, etc.”
Wipe things down thoroughly after any homemade projects like jams, pickles, or homebrew. On a less appetizing note, dirty mops and cleaning rags can also be alluring places for fruit flies to breed, with their siren songs of trapped moisture and fermenting organic matter. Wash and refresh them more frequently in the summer.
DIY FRUIT FLY TRAPS THAT WORK
The same scents that draw fruit flies to your kitchen in the first place can be your key to showing them an unceremonious exit. “They like things that have that acetic acid, or vinegar smell and taste,” says Rudman.
You can certainly order commercial fruit fly traps, but the DIY version is easy and effective. You probably have all the materials in your kitchen already.
Most traps involve luring the flies into a container of sugary vinegar or some other come-hither rotting fruit situation. The blog Young House Love conducted an experiment and found the most success putting rotting strawberries and banana peel in a tall glass.
Place plastic wrap on the top, punch a few small holes, and the flies will follow the scent into the trap but won’t be able to find their way back out. If the idea of rotting fruit on display on your kitchen counter doesn’t appeal, apple cider vinegar is also effective. Pour a few tablespoons in the container of your choice, top it with plastic wrap, punch a few holes in the top, and set it on the counter or somewhere near the flies.
Beyond the Common Fruit Fly
While Drosophila melanogaster is generally harmless, its invasive siblings can cause agricultural, and economic harm here in Washington state. The spotted-wing drosophila arrived around 2009. While the common fruit fly prefers overripe fruit, this one lays its eggs in unripe or ripening cherry and berry crops, causing costly damage for farmers. Rudman calls it “the number one pest for several fruits in the region.”
Rudman didn’t arrive at WSU with a background in agriculture, but he now applies genetics research to issues like pest control. As a scientist, especially a geneticist, the organism you study is one you have to be comfortable sacrificing, he says. “The heart doesn’t hurt so much when you’re sacrificing a fruit fly.”