1. Female worms deposit eggs in a sticky, gelatinous substance that sticks to the skin around the anus.
2. Infection begins when the pinworm eggs are swallowed. Eggs are often swallowed when people touch their mouth after they scratch the area around the anus or handle clothes or other objects (such as bedspreads) that have eggs on them. Occasionally, handling contaminated objects causes a few eggs to become airborne, and the eggs are swallowed.
3. After being swallowed, the eggs travel to the small intestine, where they hatch and release larvae.
4. The larvae then move to the large intestine. There, the larvae mature within 2 to 6 weeks, and the adult worms mate.
5. At night, the pregnant female worm moves to the rectum and exits through the anus to lay eggs.
Image from the Centers for Disease Control and Prevention, Global Health, Division of Parasitic Diseases and Malaria.