Pinworms in poop look like tiny moving pieces of white thread, about 2 to 13 millimetres long, and are usually seen on the surface of stool, on toilet paper or around the anus at night, when female worms crawl out to lay eggs. The typical symptom is intense anal itching, especially at night. Pinworm infection is common, particularly in school-age children and their families, and is easily treated with anti-parasitic medicine such as mebendazole, albendazole or pyrantel pamoate — usually two doses two weeks apart, often for the whole household — combined with strict handwashing and washing bedding. A doctor can confirm the diagnosis with a simple tape test.
Seeing worms in stool is alarming, but pinworms (also called threadworms) are the most common worm infection in many high-income countries and are rarely serious. This guide explains how to recognise pinworms and tell them apart from things that look similar, how the infection spreads, which symptoms to expect in children and adults, how doctors confirm it, what treatment and household measures work, and when you should see a doctor.
What are pinworms?
Pinworms (Enterobius vermicularis) are small intestinal roundworms that live only in humans. After someone swallows microscopic eggs, larvae hatch in the small intestine and mature in the large intestine over about one to two months. At night, adult females travel to the skin around the anus to lay thousands of sticky eggs, which cause itching. Scratching transfers eggs to the fingers and nails, and from there to the mouth, surfaces and other people.
What do pinworms look like in poop?
- colour: white or off-white, like a piece of cotton thread;
- size: females about 8 to 13 mm, males smaller, about 2 to 5 mm;
- shape: thin, thread-like, sometimes with a pointed tail;
- movement: fresh worms may wiggle; dead ones look like short white threads;
- where you see them: on the surface of stool, on toilet paper, in underwear, or around the anus one to two hours after falling asleep.
Pinworm eggs are invisible to the naked eye and are rarely found in stool samples, which is why a tape test is used for diagnosis.
Pinworms or something else? Common lookalikes
| What you see | How it looks | Is it moving? | What it usually is |
|---|---|---|---|
| Tiny white threads | 2–13 mm, thin, white | Often yes | Pinworms |
| Yellow, green or orange strands | Irregular fibers | No | Undigested food such as banana, vegetables or seeds |
| Clear or whitish stringy material | Soft, slimy | No | Mucus |
| Flat rice-grain pieces | Flat, white segments | Sometimes | Tapeworm segments — see a doctor |
| Large pale worm | 15–35 cm, pencil-thick | Yes | Roundworm (Ascaris) — see a doctor |
Symptoms of pinworms
- itching around the anus, worse at night;
- restless sleep, waking at night, irritability — especially in children;
- visible worms around the anus, in stool or on underwear;
- vaginal itching or discharge in girls and women if worms migrate;
- skin irritation or infection from scratching;
- occasionally mild abdominal discomfort or poor appetite.
Many people, particularly adults, have no symptoms at all and only discover pinworms when a child in the family is diagnosed.
How pinworms spread
- eggs pass from the anal area to the fingers during scratching or wiping;
- eggs are swallowed after touching the mouth, food or drinks;
- eggs contaminate bedding, clothing, towels, toys, toilet seats and door handles, where they can survive for up to two to three weeks;
- eggs can become airborne when bedding is shaken and be swallowed;
- a person can reinfect themselves repeatedly — this is why the second dose matters.
Pinworms spread easily in households, schools and daycare. Human pinworms do not infect pets, so animals cannot pass them to people.
How pinworms are diagnosed
The most reliable test is the tape test: clear adhesive tape is pressed against the skin around the anus first thing in the morning, before washing or using the toilet, and examined under a microscope for eggs. Repeating it on three consecutive mornings increases the chance of detection. A doctor may also identify worms you have seen or photographed. Stool samples are usually less useful because eggs are laid outside the intestine.
Treatment for pinworms
| Medicine | How it’s typically used | Notes |
|---|---|---|
| Mebendazole | One dose, repeated after two weeks | Available over the counter in some countries, by prescription in others |
| Pyrantel pamoate | One dose based on body weight, repeated after two weeks | Available over the counter in the US and Canada |
| Albendazole | One dose, repeated after two weeks | Usually prescription only |
Follow the package instructions or your doctor’s advice on dosing. Ask a doctor or pharmacist before treating children under two years old, during pregnancy or breastfeeding, or if you take other medicines. Because eggs survive the first dose, the second dose about two weeks later is essential, and doctors often recommend treating all household members at the same time.
Home measures that stop reinfection
- wash hands with soap and water after using the toilet, after changing diapers and before eating;
- keep fingernails short and discourage nail biting and scratching;
- shower each morning to remove eggs laid overnight — showers are better than baths;
- change underwear, pajamas and bedding daily for several days after treatment;
- wash bedding, towels and clothes in hot water and dry them on a hot setting;
- vacuum floors and wipe toilet seats, handles and toys;
- don’t shake bedding, which can spread eggs into the air.
Pinworm itching is intense but usually easy to tell apart from rashes; if you also notice unexplained skin changes, our guide to red patches on the skin explains when to worry.
Pinworms in children, adults and during pregnancy
- Children: most commonly affected, especially at school age; watch for night-time itching and restless sleep, and let the school or daycare know if advised.
- Adults: often catch pinworms from children and may have mild or no symptoms, but still need treatment to break the cycle.
- Pregnancy and breastfeeding: talk to a doctor before taking any medicine; hygiene measures alone may be recommended at first.
When to see a doctor
- to confirm the diagnosis before starting treatment;
- if symptoms return after two courses of treatment;
- for children under two, or during pregnancy or breastfeeding;
- if worms don’t look like pinworms or are large, flat or segmented;
- if you have abdominal pain, weight loss, diarrhea, blood in stool, or signs of skin infection from scratching.
Persistent abdominal pain is not typical of pinworms; our article on upper belly pain covers causes that need medical attention.
Frequently asked questions
What do pinworms look like in poop?
Pinworms look like tiny pieces of white cotton thread, usually about 2 to 13 millimetres long. Females are larger than males. They may move slightly when fresh and are most often seen on the surface of stool, on toilet paper, in underwear or around the anus at night.
Are pinworms in poop dangerous?
Pinworms are usually harmless but annoying. The main symptom is itching around the anus, especially at night, which can disturb sleep. Complications are uncommon but can include skin infection from scratching and, in girls and women, vaginal irritation or urinary tract infection.
How do you get rid of pinworms?
Pinworms are treated with anti-parasitic medicine such as mebendazole, albendazole or pyrantel pamoate, usually as one dose followed by a second dose two weeks later to kill worms that hatched from remaining eggs. Doctors often recommend treating everyone in the household at the same time, alongside strict handwashing and washing bedding and underwear.
Are pinworms contagious?
Yes. Pinworm eggs pass easily from the fingers to surfaces, bedding, toys and food, and can survive for up to two to three weeks. People become infected by swallowing the eggs. Pets do not carry human pinworms, so there is no need to treat dogs or cats.
Why do I keep getting pinworms?
Reinfection is common because eggs under fingernails or on bedding restart the cycle. Missing the second dose, treating only one family member, nail biting or scratching at night are the usual reasons pinworms come back.
When should I see a doctor about worms in poop?
See a doctor to confirm the diagnosis before treatment, especially for children under two, during pregnancy or breastfeeding, if symptoms return after treatment, or if you notice weight loss, abdominal pain, blood in stool, or worms that do not look like pinworms.
Sources
- Centers for Disease Control and Prevention (CDC). Pinworm infection: causes, diagnosis and treatment.
- NHS. Threadworms: symptoms, treatment and prevention.
- Mayo Clinic. Information on pinworm infection in children and adults.
Medical disclaimer: This article is for informational purposes only and does not replace advice from a healthcare professional. Always consult a doctor or pharmacist before starting treatment.