The best homemade fruit fly trap is a small jar with about an inch of apple cider vinegar and a drop of dish soap, covered with plastic wrap or a lid with a few small holes. The vinegar’s smell draws the flies in, and the soap breaks the surface tension so they sink and drown instead of landing on top. Set one or two traps where you see flies, refresh the bait every few days, and get rid of what they’re breeding in: overripe fruit, a slimy drain, a damp mop, or unrinsed recycling. A trap catches adults, but cleaning up the source is what ends the problem.
Most guides show one trap and stop there. This guide compares the common designs, explains why some backfire, and covers the breeding spots that keep fruit flies coming back, including in the garden and compost pail.
How to Make a Fruit Fly Trap That Works
You’ll need a small glass jar or cup, apple cider vinegar, dish soap, and plastic wrap or a jar lid.
- Pour in the bait. Add about an inch of apple cider vinegar to a juice glass, baby food jar, or yogurt cup. University of Nebraska Extension in Lancaster County recommends this setup (UNL Extension on fruit flies).
- Add one drop of dish soap and swirl gently. Don’t stir it into foam.
- Cover the top. Stretch plastic wrap tight and hold it with a rubber band, or use a jar lid.
- Make small holes. Poke 3 to 6 holes with a toothpick or skewer, just big enough for a fly. University of Maryland Extension says a tiny hole lets flies in but makes it hard for them to get out (UMD Extension fruit flies).
- Place it where flies gather, such as next to the fruit bowl, sink, trash can, or compost pail.
- Refresh it every 3 to 5 days, or sooner if it fills up or dries out.
Adding a small piece of very ripe banana or peach to the vinegar can make the trap even more attractive. Keep the liquid, though, since that’s what kills the flies.
Why the dish soap matters
UNL Extension explains that dish soap lowers the surface tension of the vinegar. Without it, flies can land on the liquid, drink, and fly off. With it, they sink and drown. One drop is enough. Too much soap can make foam and a heavy scent you don’t need.
Which DIY Trap Design Catches the Most?
A Kitchn writer set four homemade traps side by side for most of a week on a windowsill near ripe bananas and watermelon (The Kitchn DIY trap test).
| Trap design | Bait | Flies caught | Notes |
|---|---|---|---|
| Jar with holes in the lid | Vinegar and dish soap | At least 50 | Clear winner, easy to empty |
| Plastic wrap over a jar | Vinegar and dish soap | About 8 to 10 | Wrap can loosen or tear |
| Wine bottle with leftover wine | Wine and dish soap | 4 or 5 | Narrow neck, used a different bait |
| Paper cone in a jar | Vinegar and dish soap | Very few | Cone is fiddly to fit |
That was one informal test in one kitchen, so treat it as a guide, not proof. Still, it matches what extension services suggest: a vinegar trap with small openings works well, and fancy setups don’t add much.
The Mistake That Makes Fruit Flies Worse
Breeding warning: A trap baited with only fruit, with no liquid to drown the flies, can turn into a nursery. University of Kentucky entomologists say a female can lay up to about 500 eggs on fermenting food, and the full life cycle can finish in about a week (University of Kentucky fruit fly guide). If you use a fruit-only trap, seal it and throw it out within a day or two, long before larvae can grow into new adults.
This is the most common complaint in online threads about the popular “fruit under plastic wrap” trick. The trap fills up fast, but if it sits for days, it produces more flies than it catches.
Best Baits for a Fruit Fly Trap
| Bait | How well it works |
|---|---|
| Apple cider vinegar with dish soap | Strong lure and the most common pick |
| Leftover red wine or beer with dish soap | Works well for many people |
| Vinegar plus a piece of ripe fruit | Extra pull, but keep liquid in the jar |
| Ripe fruit alone, no liquid | Catches flies but can let them breed |
| White vinegar | Works, but smells less like fruit |
Fruit flies are drawn to fermenting smells, so the “fruitier” the bait, the better. If flies ignore your trap, try a different bait or move the trap closer to where they’re breeding.
Homemade vs. Store-Bought Traps: Pros and Cons
| Pros | Cons |
|---|---|
| Costs almost nothing | Needs refreshing every few days |
| Uses things you already have | Can look messy on a counter |
| Easy to make several at once | Can spill if knocked over |
| No chemicals beyond soap and vinegar | Store-bought traps look neater and last longer |
Store-bought traps usually use a vinegar or fruit-scented liquid in a small closed container, or a sticky card. They work on the same idea. If you buy one, follow the label and don’t expect it to fix the problem alone.
Find and Remove the Breeding Source
A trap only catches adults. Iowa State University Extension says the most effective step is to find and clean the place where larvae are growing (Iowa State Extension on fruit flies). Check these spots:
- Fruit and vegetables. Eat, refrigerate, or toss anything overripe. Check onions and potatoes in the pantry, too. Soft but still good vegetables can go into a stew, as our guide to using a slow cooker shows.
- Drains and garbage disposals. Iowa State says slow or rarely used drains with slime inside are a top source. Scrub the inside of the drain with a brush, or pour boiling water slowly down the sides. It notes that bleach and ammonia don’t help.
- Trash and recycling. Rinse bottles and cans, and empty bins often.
- Mops, sponges, and rags. Wring them out and let them dry fully.
- Wet spots. Leaks under sinks or behind the fridge can hold enough food and moisture for larvae.
To test a drain, tape a clear plastic bag or a piece of plastic wrap over it overnight. If flies are trapped under it in the morning, that drain is breeding them.
UNL Extension notes that once the food source is gone, it can take a couple of weeks for the last adults to die. Keep your traps out until you stop catching flies.
Fruit Flies in the Garden and Compost Pail
Late summer and fall bring the worst fruit fly season, partly because ripe harvests come indoors. UMD Extension says indoor numbers peak in late summer and fall.
- Bring in only what you’ll use soon. Refrigerate ripe tomatoes, berries, and stone fruit, or cut away damaged spots right away.
- Sort harvests outside and toss split or bruised fruit in the compost pile, not the kitchen.
- Seal the kitchen compost pail, empty it every day or two, and rinse it. UNL suggests freezing scraps until compost day.
- Bury food scraps in the outdoor pile under a layer of browns, like dry leaves, so flies can’t reach them.
- Change vase water on fresh-cut flowers every couple of days. Our guide on how to dry flowers is a good way to keep garden blooms without a vase of water that can turn sour.

Is It a Fruit Fly or Something Else?
| Insect | What it looks like | Where it breeds |
|---|---|---|
| Fruit fly | Tan body, red eyes, about 1/8 inch | Ripe fruit, drains, trash |
| Fungus gnat | Thin, dark, long legs | Damp houseplant soil |
| Drain fly | Fuzzy, moth-like, gray wings | Slime inside drains |
Vinegar traps work best on fruit flies. Fungus gnats are a houseplant soil problem, so letting the top inch of soil dry out between waterings usually helps more than a trap.
Iowa State notes that fruit flies are drawn to light, so you often see them on windows. Fly specks on the glass come off with the method in our guide on the best way to clean windows. University of Kentucky also recommends tight 16-mesh screens on windows and doors, and our guide to door weather stripping helps close gaps around doors. If you run a restaurant or cafe in Central Oregon, our commercial window cleaning service keeps storefront glass free of specks and smudges.
Frequently Asked Questions
How long does it take a fruit fly trap to work?
You’ll often see flies in the trap within a few hours. Clearing an infestation takes longer, usually one to two weeks, because new adults keep hatching until you remove the breeding source.
Why are fruit flies not going into my trap?
The bait may be too weak, the holes too small or too few, or the trap too far from where they’re breeding. Try apple cider vinegar with a piece of ripe fruit, widen the holes slightly, and move the trap next to the source.
Does white vinegar work in a fruit fly trap?
It can, but apple cider vinegar usually works better because it smells more like fermenting fruit. Leftover wine or beer is another good choice.
Where should I put a fruit fly trap?
Put it right where you see the most flies, such as next to the fruit bowl, sink, trash can, or compost pail. Use two or three traps for a bad problem.
The Bottom Line
A jar with apple cider vinegar, a drop of dish soap, and a few small holes in the cover is the simplest trap that works. Refresh it every few days, never leave a fruit-only trap sitting out, and spend most of your effort on the source: ripe produce, slimy drains, damp mops, and the compost pail. Clear those, and the trap only needs to finish off the last few flies.

3 Comments
Comments are closed.