S U M M A R YThe potential of two species of insect-parasitic rhabditid nematodes (Steinernema feltiae. Heterorhabditis heliothidis) for biological control of mushroom flies was studied in pot trials. Three Diptera that commonly infest mushroom crops were used; the larvae of Megaselia halterata (Phoridae), Heteropeza pygmaea (Cecidomyiidae) and Lycoriella auripila (Sciaridae) were all susceptible to parasitism by both nematode species. Fewer adult phorids and sciarids emerged when compost was nematode-treated and, for L . auripila, the effects of nematode applications at spawning, casing or on both occasions were compared. Casing treatments were more effective than spawning treatments; little extra benefit was gained from applying the nematodes twice. Populations of paedogenetic larvae of H.pygmaea built up rapidly in untreated compost, but were reduced when S . feltiae was applied, and were eradicated by H . heliothidis. Because they can penetrate insect cuticle, as well as natural body openings, Heterorhabditis spp. may be more suitable than Steinernema spp. for the control of mushroom fly larvae.