Phasmarhabditis hermaphrodita is a nematode parasite that infects and kills several species of slugs. The nematode is produced commercially as a biological control agent for slug pests of agriculture and horticulture. Given the difficulties of distinguishing this species from other nematode species in soil samples, very little is known about its natural ecology or its behaviour and persistence following application for biological control. Here we describe a method to quantify P. hermaphrodita in soil samples based on real time PCR. We designed primers and a dual labelled fluorescent probe that can be used to quantify numbers of P. hermaphrodita and which is capable of distinguishing this species from the morphologically identical Phasmarhabditis neopapillosa. We compared different methods whereby the entire nematode community is extracted prior to DNA extraction, and three methods to extract DNA directly from soil samples. Both nematode extraction and DNA extraction from large (10 g) samples of soil gave reliable estimates of nematode numbers, but methods which extracted DNA from small (1 g or less) soil samples substantially underestimated numbers. However, direct extraction of DNA from soils may overestimate numbers of live nematodes as DNA from dead nematodes was found to persist in soil for at least 6 days. The technique could be modified for detection and quantification of all soil borne parasitic nematodes.