Vegetable Garden Flies: How to Get Rid of Flies

Growing a vegetable garden is a rewarding experience, but along the way, you’ll need to watch out for pests and diseases. Finding vegetable garden flies buzzing about isn’t a pleasant sight, as are half-eaten vegetables and leaves.

Fungus gnats, fruit flies, black flies, leafminers, cabbage worms, and maggots are just some of the pests that can appear in your crop. Fortunately, you can use these 5 methods to get rid of them.

How to Get Rid of Vegetable Garden Flies

vegetable garden flies

Liquid Dish Soap and Water

In most instances where there’s a light infestation, a simple mix of clean water with a few drops of liquid dish soap works very well. Fill a spray bottle with water, then add anywhere between two to four drops of dish soap and apply it liberally on your vegetables.

The soap contains enzymes that will kill most crawling pests and flies in half an hour or so, and it’s safe enough that you can use it every other day or so.

For a stronger solution, you can add a teaspoon of white vinegar or apple cider vinegar to the mix. Alternatively, you can also give your vegetable plants a bath and hose off clinging insects in the process.

Mix in Companion Plants

It’s a known fact that some plants are great in keeping off vegetable flies and small insects, so consider adding a few to your vegetable garden.

Companion plants such as lavender, marigold, and basil can both prevent and shake off invading flies, and they’re all generally easy to care for. As an added bonus, you can use the flowers or leaves for dishes or decorative purposes.

Add Sticky or Liquid Traps

The same mixture of dish soap and vinegar can help you catch vegetable flies and kill them. Using a tall glass or a plastic container, add a few drops of liquid soap and apple cider vinegar then place them near your vegetables.

Houseflies and pests will get attracted to the vinegar and they’ll fall right in. However, since there’s liquid soap they won’t be able to get out.

Vinegar is the most common and cost-effective component you can get. If you don’t have it around, then sugar, honey, or leftover fruits can work in a pinch. Alternatively, you can put a few drops of peppermint, rosemary, thyme, or clove around your vegetables or spray them on both the top and underside of plants.

Observe Regular Cleanup of Vegetable Debris

All flies are attracted to decaying matter, and more so if it’s plant-based. You’ll know when you should clean up when there are maggots in the soil and underneath your vegetables. It’s not recommended, however, that you wait until you see worms and maggots before you clear plant debris- schedule it regularly, such as every week or two as well as when you’ve finished harvesting or are about to transplant new seedlings.

To prepare the soil, you should dig up a few inches and scan for leftover plants and roots. Pick any worm or maggot you see and put them in a bucket of soapy water.

Use a Vegetable-Friendly Pesticide Spray

You can turn to a pesticide spray if all else fails and there are still a lot of pests in your vegetable garden. If the DIY mixes and traps don’t work well enough to eradicate the flies hovering and eating your plants, then you can resort to an organic and vegetable-friendly pesticide.

Chemical pest control should be the last resort in clearing out flies from your vegetable garden. Make sure that you follow the manufacturer’s instructions on the label and don’t spray too often.

The Most Common Vegetable Garden Flies

vegetable garden flies

Keep an eye out for these vegetable garden flies so you can quickly get rid of them:

Fungus Gnats

Fungus gnats infest soil and organic matter and appear as thin mosquitoes with dark green wings. These insects spread their larvae in the soil, which eats up roots, stems, and compost.


Blackflies are small aphids that usually form on the underside of vegetables. In groups, black flies tend to form a noticeable cluster and bring with them ants. Left unchecked, these tiny creatures will weaken and eventually kill your vegetables.

Cabbage Worms

Cabbage worms are your typical green worms that feed on leafy greens such as cabbage, broccoli, and others. They tend to hide during the day and cause significant destruction at night.

Related Article: Does Dish Soap Repel Ants?