Why Did I Shit Myself in My Sleep?

Nocturnal fecal incontinence happens when the body’s normal safeguards against bowel leakage are overwhelmed during sleep. Your anal sphincter pressure naturally drops as you enter deeper sleep stages, and while the colon usually stays quiet overnight, a range of triggers can push stool through that weakened gate. If this has happened to you once after a rough night of drinking or a stomach bug, it is almost certainly a one-off. If it keeps happening, something specific is going on with your gut, your nerves, your pelvic floor, or a medication you take, and it is worth figuring out which.

What Normally Keeps You Continent at Night

Your body has a surprisingly sophisticated system for keeping things sealed while you sleep, and understanding how it works makes it easier to see where it can break down. The anal sphincter is not a simple on-off valve. It cycles through patterns of activity around the clock, including spontaneous relaxations that happen several times an hour even in completely healthy people.1PubMed. Spontaneous variation of anal “resting” pressure in healthy humans So the sphincter is constantly opening and closing a little bit, and yet most people never leak. That is because the system has backup layers: rectal sensation that can wake you up, pelvic floor muscles that contract reflexively, and a colon that dramatically slows its activity at night.

Colonic motility follows a circadian rhythm. During the day, especially after waking up and after meals, the colon moves stool along. At night, that activity drops to a minimum.2Europe PMC. Disruption of Circadian Rhythms and Gut Motility: An Overview of Underlying Mechanisms and Associated Pathologies So in a healthy body, even though the sphincter loosens during deep sleep, there is very little stool being pushed toward the exit. Nocturnal incontinence happens when something disrupts either side of that equation: the colon becomes abnormally active at night, or the sphincter and pelvic floor are too weak to handle even normal overnight pressures.

How Deep Sleep Weakens the Sphincter

Research on healthy volunteers shows that anal resting pressure drops progressively as sleep deepens. In one study, pressure fell from an average of about 57 mmHg while awake to around 43 mmHg during deep sleep, roughly a 25% decline.3PubMed. Influence of sleep on anal sphincteric pressure in health and after ileal pouch-anal anastomosis That drop is completely normal and does not cause problems on its own. But if your baseline sphincter strength is already compromised for any reason, that sleep-related dip can take you below the threshold needed to hold things in. Think of it like a car’s brakes: if they are already worn thin, they might hold on flat ground but fail on a hill. Deep sleep is the hill.

This also explains why people who have a borderline sphincter issue during the day might only notice actual leakage at night. Daytime, you have conscious control, you are upright (gravity helps), and your sphincter pressure is higher. At night, all three of those advantages disappear at once.

One-Off Episodes and Their Usual Culprits

If this happened once or twice and you can connect it to a specific event, the cause is usually temporary and straightforward. The most common one-off triggers involve anything that floods the colon with liquid stool overnight, overwhelming the sphincter’s reduced capacity during sleep.

  • Heavy drinking: Alcohol speeds up gut transit time and can produce loose, watery stools. Combine that with the fact that being drunk makes you sleep more deeply and raises your arousal threshold, and you have the perfect setup for an overnight accident.
  • Acute gastroenteritis: A stomach bug (viral or bacterial) can produce such urgency and volume that even a perfectly healthy sphincter cannot hold back the tide, especially during sleep when you cannot consciously respond to the sensation of rectal filling.
  • Dietary overload: Large amounts of sugar alcohols found in sugar-free gum, candies, and protein bars can cause osmotic diarrhea, meaning they pull water into the colon and create an unusually liquid stool. This effect is worse in people who are not accustomed to consuming these sweeteners.4Europe PMC. Gastrointestinal Disturbances Associated with the Consumption of Sugar Alcohols with Special Consideration of Xylitol: Scientific Review and Instructions for Dentists and Other Health-Care Professionals
  • Caffeine or spicy food late at night: Both can stimulate colonic contractions. If the colon is active during hours it would normally be quiet, stool can arrive at the rectum while you are asleep and your sphincter is relaxed.

In all of these scenarios, the common thread is an unusual amount of liquid stool meeting a sphincter that has naturally loosened for the night. If the event does not repeat, there is usually nothing structurally wrong.

Medications That Can Cause Overnight Accidents

Several commonly prescribed medications can tip the balance toward nighttime incontinence, and this is one of the most under-recognized causes. Metformin, one of the most widely prescribed drugs for type 2 diabetes, is a significant culprit. It is independently associated with chronic diarrhea and with fecal incontinence itself.5PubMed. Oral hypoglycaemic drugs and gastrointestinal symptoms in diabetes mellitus Case reports describe patients developing explosive watery diarrhea after years of stable metformin therapy, with all symptoms resolving once the medication was discontinued.6PubMed. Metformin as a cause of late-onset chronic diarrhea The key detail here is that this can appear years into treatment, not just in the first weeks, so patients and doctors may not connect the dots.

Beyond metformin, other medication classes that can contribute include magnesium-based antacids and supplements (magnesium is a well-known stool softener at higher doses), orlistat (a weight-loss drug that blocks fat absorption, producing oily stools that can leak out), and certain antibiotics that disrupt gut flora. SSRIs, commonly prescribed for depression and anxiety, can also increase gut motility in some people. If your overnight incontinence started or worsened around the time you began a new medication, that is worth bringing up with your doctor.

Nerve Damage and Diabetes

Diabetes deserves its own discussion because it can cause nocturnal fecal incontinence through multiple pathways simultaneously. First, diabetes can damage the pudendal nerve, which controls the external anal sphincter. In one study, pudendal nerve conduction was abnormally slow in the vast majority of diabetic patients with fecal incontinence, and rectal sensitivity thresholds were also elevated, meaning the rectum needed to be more full before the patient could even sense it.7PubMed. Pudendal neuropathy in diabetic patients with faecal incontinence Second, autonomic neuropathy in diabetes can alter bowel motility patterns, disrupting the normal circadian quieting of the colon at night. Third, as already discussed, metformin itself can cause diarrhea and incontinence.

So a person with long-standing diabetes could face a triple hit: their sphincter is weaker because of nerve damage, their rectum cannot feel stool arriving, and their medication is making the stool looser. Any one of those alone might not cause a problem. Together, especially at night when sphincter pressure is at its lowest, they can produce regular episodes. If you have diabetes and this is happening to you, your doctor needs to evaluate all three pathways rather than assuming it is just one thing.

Childbirth Injuries and the Pelvic Floor

Vaginal delivery is the most common cause of anal sphincter damage in women of reproductive age, and many women are never told about it. A landmark study using endoanal ultrasound found that about a third of first-time mothers who delivered vaginally had a detectable sphincter defect six weeks postpartum, and the damage persisted in every woman re-examined at six months.8PubMed. Anal-sphincter disruption during vaginal delivery Among these women, there was a strong association between the sphincter defect and the development of bowel symptoms including incontinence and urgency.

Not every sphincter defect leads to incontinence right away. Many women live with an undiagnosed partial tear for years. The problem often surfaces later, sometimes after a second delivery compounds the original injury, or as age-related muscle loss further weakens the sphincter. A population-based study found that forceps delivery and third- or fourth-degree perineal tears during childbirth were independent risk factors for fecal incontinence.9PubMed Central. Anal incontinence after childbirth If you have had a complicated vaginal delivery and are now experiencing overnight leakage, the connection may not be obvious, especially if years have passed, but it is worth investigating.

Aging and Sphincter Decline

Even without childbirth injury, nerve damage, or any specific medical condition, the anal sphincter loses strength over time. Research shows an age-related increase in both anal incontinence and sphincter muscle atrophy, driven in part by fibrotic changes where functional muscle tissue is gradually replaced by scar-like tissue.10PubMed. Age-related external anal sphincter muscle dysfunction and fibrosis: possible role of Wnt/β-catenin signaling pathways This is a slow, progressive process. Most people compensate without realizing it, perhaps clenching more consciously during the day or avoiding certain foods. But sleep removes conscious compensation, and the overnight pressure drop described earlier can push an aging sphincter past its limit.

Inflammatory bowel disease compounds age-related risk. In a study of patients with Crohn’s disease or ulcerative colitis, about 7% reported nocturnal leakage specifically, and patients aged 50 and older were roughly 1.7 times more likely to experience fecal incontinence than younger patients.11Oxford University Press. Addressing Fecal Incontinence in Inflammatory Bowel Disease Patients: A Messy Problem So for people with IBD, age amplifies an already elevated risk.

Disrupted Circadian Rhythms and Shift Work

Your colon’s circadian clock is not just a background detail. Disrupted circadian rhythms have been linked to digestive conditions including irritable bowel syndrome and abnormal bowel motility patterns.2Europe PMC. Disruption of Circadian Rhythms and Gut Motility: An Overview of Underlying Mechanisms and Associated Pathologies If you work night shifts, travel across time zones frequently, or have a chaotic sleep schedule, your colon may not properly suppress activity during the hours you are asleep. Instead of the normal overnight quiet, the colon may be pushing stool through at times when your sphincter has relaxed for sleep. Shift workers who eat large meals during unconventional hours can compound the problem, because the colonic response to eating (the gastrocolic reflex) does not care what time the clock says.

This is one of the less-discussed contributors to overnight fecal incontinence, but for people with irregular schedules who cannot find another explanation, it is worth considering. Keeping meal timing consistent, even when sleep timing cannot be, can help the colon settle into a more predictable pattern.

When to Take It Seriously

A single episode after obvious triggers like illness, heavy drinking, or food poisoning does not usually require medical investigation. You should see a doctor if any of the following apply:

  • Recurrence: More than two or three episodes over a few months, or a pattern of increasing frequency.
  • Daytime symptoms too: Urgency, difficulty making it to the bathroom in time, or small amounts of leakage during the day suggest a structural or neurological issue rather than a one-off dietary trigger.
  • Associated symptoms: Blood in the stool, unexplained weight loss, persistent abdominal pain, or fever alongside the incontinence warrants prompt evaluation to rule out infections and inflammatory conditions.
  • Recent medication changes: If the episodes line up with starting or increasing a medication dose, bring a medication list to your appointment.
  • History of childbirth injury or pelvic surgery: Even if it was years ago, prior trauma to the pelvic floor can manifest later, especially as age-related changes compound the original damage.

Doctors can evaluate the anal sphincter’s function and structure using tools like endoanal ultrasound, which provides an image of the sphincter muscles, and anal manometry, which measures the actual pressure the sphincter can generate.12Europe PMC. Diagnostic testing for fecal incontinence These tests are not invasive or particularly painful, and they can distinguish between a weak sphincter, a structural defect, and a nerve conduction problem, each of which has different treatment implications.

What Can Be Done About It

Treatment depends entirely on the cause, which is why diagnosis matters. But a few approaches apply broadly. Pelvic floor rehabilitation, which includes targeted exercises and sometimes biofeedback training, has reported success rates between 50 and 80% across multiple studies.13Europe PMC. Pelvic floor rehabilitation in the treatment of fecal incontinence This works by strengthening the muscles that support the sphincter, improving the ability to squeeze and hold when the rectum fills. It is usually the first-line approach for mild to moderate incontinence regardless of the underlying cause.

For medication-related diarrhea, the fix can be as simple as switching drugs. If metformin is the culprit, an extended-release formulation sometimes reduces gastrointestinal side effects, or an alternative diabetes medication may be warranted. For people whose sphincter is structurally damaged, surgical repair is an option, though it is typically reserved for cases where conservative measures have failed. Newer approaches like sacral nerve stimulation, which uses a small implanted device to modulate the nerves controlling the sphincter, have expanded the options for people who do not respond to physical therapy or who are not good candidates for surgery.

Practical overnight strategies can help manage the situation while you work on the underlying cause. Avoiding large meals and known trigger foods in the two to three hours before bed reduces the chance that the colon will be actively pushing stool through while you sleep. Limiting alcohol, especially in large quantities, removes one of the most common acute triggers. Some people find that having a bowel movement before bed, sometimes aided by a small dose of fiber supplement taken earlier in the day, helps empty the rectum enough that there is simply less stool available to leak overnight.

Why People Do Not Talk About This

One of the biggest barriers to getting help is the intense shame people feel about fecal incontinence. Research on patients with inflammatory bowel disease found that embarrassment leads many to avoid discussing the problem even with their own doctors, resulting in anxiety, depression, social isolation, and withdrawal from activities they used to enjoy.14PubMed Central. Addressing the overlooked psychological and social impact of fecal incontinence in inflammatory bowel disease patients The unpredictability of overnight episodes adds to the distress: people start dreading sleep, avoiding overnight travel, and declining to share a bed with a partner.

The reality is that fecal incontinence is far more common than most people realize, and doctors see it regularly. It is not a character flaw or a hygiene problem. It is a mechanical issue with your body’s continence system, and like most mechanical issues, it is usually fixable or at least manageable once you know what is going wrong. The hardest step is often just bringing it up at a medical appointment. One practical approach: write it down before your visit so you do not have to find the words in the moment. Most doctors will respond matter-of-factly and move straight into evaluation, because to them it is a diagnostic puzzle, not a social catastrophe.

Sleep Conditions That Can Complicate Things

It is worth noting that certain sleep disorders can indirectly raise the risk of overnight incontinence. Obstructive sleep apnea, for instance, fragments sleep architecture and can increase the time spent in deep sleep stages during certain parts of the night (as the body tries to recover from disrupted rest), which could deepen the sphincter pressure drop. Heavy sedation from sleep medications or benzodiazepines raises arousal thresholds, making it harder for the brain to wake you up in response to rectal filling. Similarly, consuming large amounts of alcohol acts as both a sedative and a gut irritant, which is why alcohol-related episodes are so common.

People who take prescription sleep aids and notice overnight incontinence should mention both the sleep medication and the bowel issue to their doctor, since the two may be connected. The goal is not necessarily to stop the sleep medication but to adjust timing, dosage, or add strategies that reduce the chance of the colon being active during the deepest sedation window.