Why Do I Poop in My Sleep? Causes and Treatments

Passing stool during sleep, known medically as nocturnal fecal incontinence, happens because the muscles that normally keep the anal canal closed relax as you move into deeper stages of sleep, and when that natural pressure drop combines with an underlying condition that stresses the system, accidents can occur. Globally, fecal incontinence of any kind affects roughly 8% of the population, with higher rates among older adults and women.1Clinical Gastroenterology and Hepatology. Global Prevalence and Burden of Fecal Incontinence: A Systematic Review and Meta-Analysis Nighttime episodes specifically are less common than daytime leakage, but they are far from rare, and they tend to point toward identifiable medical problems rather than being something you simply have to live with.

Why Your Body Usually Keeps Things Under Control at Night

Your colon has a built-in schedule. During the day, especially after waking and after meals, your gut ramps up its contractions to move stool along. At night, that activity drops sharply. Healthy people have minimal colonic motility while they sleep, which means the colon is largely quiet and not pushing stool toward the rectum in the first place.2PubMed Central. Disruption of Circadian Rhythms and Gut Motility: An Overview of Underlying Mechanisms and Associated Pathologies On top of that, the internal anal sphincter maintains a resting tone even while you sleep, acting as a passive barrier. So two defenses work together: your colon slows down, and your sphincter holds firm.

But “holds firm” does not mean “holds at full strength.” Research using pressure sensors and polysomnography (sleep-stage monitoring) has shown that anal canal resting pressure drops progressively as sleep deepens. In healthy volunteers, average resting pressure fell from about 57 mmHg while awake to around 43 mmHg in deep sleep, and the pressure also fluctuated substantially from minute to minute.3PubMed. Influence of sleep on anal sphincteric pressure in health and after ileal pouch-anal anastomosis In most people that reduced pressure is still enough to prevent leakage, because the colon is not actively pushing stool into the rectum at that hour. Problems start when one or both of those defenses are weakened by disease, injury, or medication.

Inflammatory Bowel Disease and Chronic Gut Conditions

If you have Crohn’s disease, ulcerative colitis, or another form of inflammatory bowel disease, nighttime fecal accidents are a recognized complication. In one study of about 500 IBD patients, roughly 14% reported fecal incontinence during the day or night, and about 7% reported nighttime leakage specifically.4PubMed Central. Fecal Incontinence in Inflammatory Bowel Disease A separate survey from a Swiss IBD clinic found that nearly 30% of respondents had experienced fecal incontinence in the preceding four weeks, with several factors raising the odds: having more than three bowel movements per day, nighttime bowel movements, active diarrhea, blood in the stool, and disease duration beyond 15 years.5PubMed Central. Fecal Incontinence in Inflammatory Bowel Disease (IBD): Associated Factors and Impact on the Quality of Life of Patients in an IBD Clinic in Switzerland

What connects these risk factors is that active inflammation makes the rectum irritable and less able to store stool. When the lining is inflamed, it takes less stool volume to trigger an urgent contraction, and urgency that overwhelms the sphincter during the day can just as easily overwhelm the weakened sphincter at night. If your IBD is in a flare, nighttime accidents are a sign that your disease activity needs better control, not just that you need a different bedtime routine.

Irritable bowel syndrome with diarrhea, microscopic colitis, and radiation-induced bowel injury can produce a similar pattern. Any condition that causes loose, frequent stools effectively increases the volume and liquidity of what reaches the rectum overnight, and liquid stool is much harder for a relaxed sphincter to contain than formed stool.

Diabetes, Nerve Damage, and Autonomic Neuropathy

Long-standing diabetes is one of the more underappreciated causes of nocturnal fecal incontinence. When blood sugar stays poorly controlled for years, the autonomic nerves that regulate the digestive tract can become damaged. This diabetic autonomic neuropathy can lead to chronic diarrhea, unpredictable bowel patterns, and fecal incontinence.6PubMed Central. Diabetic autonomic neuropathy of the gastrointestinal tract The damage is not just to the nerves controlling sphincter tone; it also affects the nerves that coordinate colonic motility, meaning the gut may become active at inappropriate times, including the middle of the night.

Because the internal anal sphincter relies on continuous nerve input to maintain its tone, even mild neuropathy can reduce that baseline pressure further during sleep. Combine that with diabetes-related diarrhea and you have both a weakened barrier and more liquid stool challenging it. If you have diabetes and are experiencing nighttime accidents, it is worth bringing up with your doctor specifically in the context of neuropathy screening, since treatment of the underlying nerve damage (or at least tighter glucose management to slow its progression) is a different strategy from simply treating diarrhea symptoms.

Spinal Cord Injuries and Other Neurological Conditions

Injuries or diseases affecting the spinal cord disrupt the nerve pathways that coordinate bowel function. People with spinal cord injuries frequently develop what is called neurogenic bowel, a broad term for the constipation, fecal incontinence, and motility problems that follow the loss of normal nerve signaling to the colon and pelvic floor.7PubMed Central. Neurogenic Bowel and Management after Spinal Cord Injury: A Narrative Review The pattern depends on where the injury is. Higher spinal injuries tend to cause a “reflexic” bowel that empties unpredictably in response to rectal filling, while lower injuries can produce a “flaccid” bowel with reduced tone and passive leakage.

Multiple sclerosis, stroke, Parkinson’s disease, and spina bifida can all produce similar disruptions to varying degrees. The common thread is that if the nerves connecting the brain and spinal cord to the pelvic floor are compromised, the sphincter cannot respond to rectal filling with the kind of squeeze reflex that normally wakes a person up or at least prevents leakage during sleep. For people in these situations, nighttime bowel management often involves scheduled evacuation programs and careful timing of meals and medications rather than waiting for the bowel to signal on its own.

Overflow Incontinence From Severe Constipation

This one catches people off guard: sometimes the cause of fecal leakage is not diarrhea at all, but its opposite. When a large, hard mass of stool becomes impacted in the rectum, liquid stool higher up in the colon seeps around it and leaks out, especially at night when the sphincter is at its most relaxed. This is called overflow incontinence, and it is particularly common in older adults and people who are immobilized or on medications that slow the gut (opioids, certain antacids, iron supplements).8PubMed Central. Investigating and treating fecal incontinence: when and how

The misleading part is that the leakage looks and smells like diarrhea, so people may take anti-diarrheal medications that actually make the impaction worse. If you are experiencing watery nighttime accidents but have not had a normal bowel movement in days, overflow incontinence is a strong possibility. The treatment is to clear the impaction first, usually with enemas or manual disimpaction, and then address the underlying constipation with dietary changes, hydration, and sometimes osmotic laxatives to prevent it from recurring.

Severe Gastrointestinal Infections

Acute infections can cause diarrhea forceful enough to overwhelm even a healthy sphincter. Clostridioides difficile (C. diff) infection is a well-known example. Patients with hospital-treated C. diff have described the diarrhea as continuous, watery, and uncontrollable, preventing them from participating in daily activities and causing profound embarrassment.9Springer Link. Patients’ experience and perception of hospital-treated Clostridium difficile infections: a qualitative study When stool volume is that high and that liquid, nighttime accidents are essentially inevitable regardless of sphincter strength. Norovirus, food poisoning, and other acute gastroenteritis episodes can produce similar short-term nighttime leakage that resolves once the infection clears.

The distinction that matters here is duration. If nighttime accidents started suddenly and are accompanied by fever, cramping, or obviously watery diarrhea, an infection is the likely culprit and it should resolve with time or targeted treatment. If the episodes are ongoing or recurring without an obvious acute illness, the cause is more likely structural or neurological and warrants a deeper workup.

Shift Work, Jet Lag, and Circadian Disruption

Your gut’s daily cycle of activity and rest is governed by the same circadian clock that regulates your sleep-wake cycle. When that clock is disrupted, the gut does not always get the memo to be quiet at night. Gastrointestinal symptoms like diarrhea and constipation are more common among shift workers and frequent time-zone travelers, both groups whose biological rhythms are chronically out of sync.10PubMed Central. Role of clock genes in gastrointestinal motility

For a night-shift worker trying to sleep during the day, the colon may still be following its daytime program of increased motility, pushing stool toward the rectum at the very time the person is trying to rest. This mismatch can produce urgency or leakage during daytime sleep even in someone with no underlying bowel disease. The fix is not straightforward, since you cannot always change your work schedule, but keeping meal timing consistent, avoiding large meals close to sleep, and using fiber to maintain firm stool consistency can help reduce the risk.

Nighttime Soiling in Children

When a child poops during sleep, the situation is typically different from adult fecal incontinence. In children, the most common explanation is encopresis, which is repeated passage of stool in inappropriate places (including during sleep) after the age when toilet training would normally be complete. Encopresis happens during the day more often than at night, and the underlying cause is usually chronic constipation with overflow, sometimes combined with emotional stressors or dietary factors.11ScienceDirect. Handbook of Conceptualization and Treatment of Child Psychopathology – Chapter 19: Enuresis/Encopresis

The mechanism is similar to overflow incontinence in adults: the child becomes chronically constipated, the rectum stretches to accommodate a large stool mass, and eventually liquid stool leaks around the blockage. The child may not even be aware of it. Treatment centers on resolving the constipation, re-establishing regular bowel habits, and addressing any behavioral or emotional factors. Punishing or shaming a child for nighttime soiling is counterproductive, since the leakage is involuntary and the child is typically unable to sense or prevent it.

Conservative Treatments That Work

For many people, the first line of treatment does not involve medication or surgery. Pelvic floor rehabilitation, which includes exercises to strengthen the muscles around the anal canal, has reported success rates in the range of 50 to 80% across studies.12PubMed Central. Pelvic floor rehabilitation in the treatment of fecal incontinence Biofeedback, a technique where you learn to coordinate and strengthen your pelvic floor using real-time feedback from sensors, has shown success in more than 70% of cases in some reports, though controlled trials comparing biofeedback to standard care have tempered that optimism somewhat.13PubMed Central. Bio-feedback treatment of fecal incontinence: where are we, and where are we going? The combination of pelvic floor muscle training, biofeedback, and stool form management appears to work best when delivered by trained clinicians rather than attempted independently.14IntechOpen. Lifestyle Modifications for Faecal Incontinence in Functional Gastrointestinal Disorders: A Systematic Review of Evidence and Outcomes

Stool form management deserves its own mention because it is deceptively simple and surprisingly effective. The goal is to keep stool firm enough that a relaxed nighttime sphincter can still contain it. Practical steps include:

  • Soluble fiber: Adding psyllium husk or similar supplements bulks up stool and absorbs excess water, reducing the chance of liquid leakage.
  • Meal timing: Eating your largest meal earlier in the day gives the colon time to process before sleep, rather than pushing a gastrocolic reflex into the nighttime hours.
  • Trigger avoidance: Caffeine, alcohol, and high-fat or spicy foods can speed transit and loosen stool. Reducing or eliminating these, especially in the evening, can make a noticeable difference.
  • Bowel scheduling: Going to the bathroom at a consistent time each day, ideally after a meal, trains the bowel to empty on a schedule and reduces the amount of stool sitting in the rectum overnight.

Anti-diarrheal medications like loperamide are sometimes used to slow transit and firm stool, particularly in people with chronic diarrhea-predominant conditions. These should be used under medical guidance, since they can worsen constipation-related overflow incontinence if the underlying cause has been misjudged.

When Surgery Enters the Conversation

Surgical options exist but are generally reserved for people who have not improved with conservative treatment. The evidence base for surgery in fecal incontinence is, frankly, thin. A systematic review of surgical treatments found that most studies were of low quality, with substantial variation in outcomes and no high-quality head-to-head comparisons between different approaches. The review concluded that evidence was insufficient for all of the surgical comparisons examined.15Diseases of the Colon & Rectum. Systematic Review of Surgical Treatments for Fecal Incontinence

That does not mean surgery never helps. Sphincteroplasty (repairing a torn sphincter, often after childbirth injury) can restore continence when the problem is a clear structural defect. Sacral nerve stimulation, which uses a small implanted device to modulate the nerves controlling the pelvic floor, has gained traction as a less invasive option and works for some patients whose sphincter is intact but poorly coordinated. Injectable bulking agents placed around the anal canal can improve the seal without major surgery. But the decision to pursue any of these should come after a thorough workup and a serious trial of conservative measures, because outcomes are unpredictable and complications are real.

Protecting Your Skin

One aspect of nighttime fecal incontinence that rarely gets discussed but matters enormously is skin damage. When stool sits against skin for hours during sleep, the moisture and digestive enzymes in it start breaking down the skin barrier quickly. Research on incontinence-associated dermatitis has found that skin damage can begin within 10 to 15 minutes of contact with stool, causing overhydration, swelling, and eventual breakdown. Add the friction and shear forces from moving against sheets, and the risk of painful skin injury climbs further.16PubMed Central. Prevention and Care for Incontinence-Associated Dermatitis Among Older Adults: A Systematic Review

Barrier creams containing zinc oxide or dimethicone, applied to the perianal skin before bed, create a protective layer between the skin and any stool that may leak. Absorbent pads or protective bedding are not a long-term solution to the incontinence itself, but they reduce the duration of skin contact and make cleanup easier. Gentle cleansing with pH-balanced products rather than harsh soaps helps preserve the skin’s natural acid mantle. For people managing ongoing nighttime incontinence while pursuing treatment, these measures can be the difference between intact skin and chronic wounds.

The Emotional Weight and Why People Delay Getting Help

Perhaps the biggest barrier to treatment is that people do not talk about this problem. Fecal incontinence carries a stigma that far exceeds its medical severity, and nighttime episodes feel especially private and humiliating.17PubMed Central. Fecal Incontinence in the Elderly The psychological fallout is well documented: anxiety, depression, social withdrawal, and isolation are common consequences, driven by the unpredictability of episodes and the fear of being discovered.18PubMed Central. Addressing the overlooked psychological and social impact of fecal incontinence in inflammatory bowel disease patients

Many people endure nighttime fecal incontinence for years before mentioning it to a doctor. Some assume it is a normal part of aging. Others worry they will be dismissed or that nothing can be done. In practice, doctors who treat this condition routinely are not surprised or judgmental, and the majority of cases can be improved with the conservative approaches described above. If your current doctor does not seem to take the problem seriously, a gastroenterologist or a colorectal specialist is a reasonable next step. The condition is common enough that protocols exist, and you are not the first person to bring it up in their office, even if it feels that way.

When to Seek Urgent Medical Attention

Most nighttime fecal incontinence develops gradually and can be evaluated at a routine appointment, but certain patterns warrant faster action. If nighttime accidents appear suddenly along with fever, severe abdominal pain, or bloody diarrhea, an acute infection or IBD flare may need prompt treatment. New-onset fecal incontinence combined with leg weakness, numbness, or difficulty with bladder control could signal a spinal cord problem, including cauda equina syndrome, which is a surgical emergency. And if you notice progressive worsening of continence without any change in diet or medications, a structural problem such as a rectal prolapse or a mass may be developing and should be evaluated with imaging or endoscopy sooner rather than later.

For everyone else, the reassuring truth is that this problem has identifiable causes and treatable pathways. The hardest step is usually the first one: telling someone about it.