Onion Fly is a common pest that affects onions, shallots and leeks in Scotland. Here is what it looks like, how to spot the damage, and which controls have been tested.

What does it look like?

The adult is a 5-7mm grey fly, easily mistaken for a small house fly. The larva is what actually causes the damage: a white, legless, headless maggot that grows up to 10mm long as it feeds.

What causes it

Eggs are laid at the base of the leaves or in the soil right next to the plant, so simple proximity to an egg-laying female is what decides whether a plant gets targeted, rather than any weather condition. That sets it apart from several other soil-dwelling maggot pests on this site, where cold or wet soil is a real part of the story.

Is this pest active now?

Watch from May through the season, with damage peaking in June and July across up to three generations.

🌱 Plants at risk

Onion Fly also affects these crops:

Symptoms

Seedlings can be killed outright. On mature plants, the outer leaves yellow and wilt as larvae feed on the roots and bulb below ground, and a badly affected bulb is destroyed and inedible by the time the damage is visible above ground.

Life cycle

Adults emerge from overwinteredKeeping a plant alive and intact through the cold months, whether left outdoors, moved under cover, or stored dormant. Full definition → pupae from May onwards, with up to three generations running through the year. A single female can lay over 200 eggs, which hatch within days; larvae then feed for around three weeks before pupating in the soil for two to three weeks.

Why this matters in Scotland

Central and eastern England is where this pest is most frequent, a genuine reason to expect lighter pressure in Scotland than the general UK picture, though not a reason to rule it out.

The May emergence date is a UK-generic figure. A Scottish spring that's slower to warm up pushes both the adult flies' first appearance and the vulnerable seedling stage later too, so the useful trigger for mesh or extra vigilance is what your own onion bed actually looks like that year, not the calendar date on its own.

Controls: what actually works

All the methods below are backed by real evidence, not just repeated folklore.

Evidence-based

Grow from sets rather than seed

A set is already a small established bulb rather than a seed working through germinationA seed sprouting: breaking dormancy and putting out its first root and shoot, given the right warmth and moisture. Full definition →, which gives it a head start over the exact vulnerable early stage this pest targets.

Evidence-based

Cover the crop with insect-proof mesh

A physical barrier over the row stops adult flies reaching the plants to lay eggs in the first place, useful for both seed-sown and set-grown crops.

Evidence-based

Biological control: pathogenic nematodes watered into the soil

Sold as Fruit and Vegetable Protection, this drench targets the maggots directly in the soil, useful where mesh wasn't in place before egg-laying happened.

Evidence-based

Remove and burn badly damaged late-season plants

A plant too far gone to save is still a source of larvae and pupae if left in the ground, so removing and burning it rather than composting it keeps that population from carrying over.

Evidence-based

Encourage natural predators: birds, hedgehogs and ground beetles

All three are natural enemies that help keep populations down without any product or hand intervention needed.

Contains affiliate link
Garden insect mesh netting, 1mm ultra-fine
A barrier against the egg-laying adults is the real defence, since maggots can kill seedlings outright and destroy mature bulbs from below ground.
View on Amazon UK →
Planting CalendarGet your sowing and planting dates rightMany pests hit hardest at the seedling stage. Time your sowing to give plants the strongest start.

Frequently asked questions

What should I do first if I find onion fly in my garden?

Start with grow from sets rather than seed. After that, cover the crop with insect-proof mesh. Work through the rest in order of how well-evidenced they are if the first two aren’t enough on their own.

Will onion fly kill my plants?

Not usually outright, but it can genuinely cost you part of that year's harvest, not just something cosmetic a plant shrugs off. See the controls above for what actually reduces that risk.

When are onion fly most active in Scotland?

Check the seasonal activity section above. Scottish timings can run a few weeks behind the UK-generic figures.

Sources

4 sources, recorded with what each was used for
  • RHS1: identification, symptoms, the proximity-based egg-laying trigger, life cycle and generations, growing from sets, insect-proof mesh, nematode drench, removing damaged plants, encouraging predators, England-frequency note, absence of a chemical control
  • RHS1: confirming onion fly directly on onions' own growing page
  • RHS1: confirming onion fly directly on shallots' own growing page
  • RHS1: confirming onion fly directly on leeks' own growing page