Does cotrimoxazole (trimethoprim‑sulfamethoxazole) cause diarrhea?

Medical Advisory BoardAll articles are reviewed for accuracy by our Medical Advisory Board
Educational purpose only • Exercise caution as content is pending human review
Article Review Status
Submitted
Under Review
Approved

Last updated: March 9, 2026View editorial policy

Personalize

Help us tailor your experience

Which best describes you? Your choice helps us use language that's most understandable for you.

Does Cotrimoxazole Cause Diarrhea?

Yes, cotrimoxazole (trimethoprim-sulfamethoxazole) can cause diarrhea as a recognized adverse effect, and more seriously, it can cause Clostridium difficile-associated diarrhea (CDAD), which may range from mild diarrhea to fatal colitis.

Mechanism and Clinical Significance

Cotrimoxazole causes diarrhea through two distinct mechanisms:

Direct Gastrointestinal Effects

The FDA drug label explicitly lists gastrointestinal disturbances including nausea, vomiting, diarrhea, and anorexia as adverse effects of cotrimoxazole 1. These are well-described adverse effects of sulfonamides and appear to be more common with cotrimoxazole than with trimethoprim alone 2. The gastrointestinal side effects are among the most common reasons patients discontinue the medication 3.

Antibiotic-Associated Diarrhea and CDAD

The FDA issues a specific warning that CDAD has been reported with cotrimoxazole use 1. This occurs because antibacterial agents alter normal colonic flora, leading to C. difficile overgrowth. The warning emphasizes that:

  • CDAD can range from mild diarrhea to fatal colitis
  • It must be considered in all patients presenting with diarrhea following cotrimoxazole use
  • CDAD has been reported to occur over two months after antibiotic administration
  • Hypertoxin-producing strains cause increased morbidity and mortality

Clinical Context: Cotrimoxazole as Treatment vs. Cause

The irony is that cotrimoxazole is sometimes used to TREAT infectious diarrhea, yet it can also CAUSE diarrhea. Guidelines note that cotrimoxazole has been proven effective for traveler's diarrhea, though increasing bacterial resistance is compromising its use 4. It's recommended as a second-line agent after quinolones for empirical treatment of secretory/invasive traveler's diarrhea 4.

Impact on Gut Microbiome

Research demonstrates that prolonged cotrimoxazole treatment substantially suppresses gram-negative aerobic flora while moderately increasing yeasts 5. This microbiome disruption contributes to both direct gastrointestinal symptoms and secondary diarrhea/colitis 4. Studies in HIV-exposed infants show cotrimoxazole prophylaxis increases dysbiosis over time and interferes with healthy microbiota development 6.

Risk Factors and Clinical Pitfalls

Key risk factors for developing diarrhea with cotrimoxazole include:

  • Prolonged treatment duration
  • Higher doses
  • Underlying gastrointestinal disturbances
  • Concurrent medications affecting gut flora
  • Recent or concurrent antibiotic use

Critical pitfall: Do not dismiss new-onset diarrhea in patients on cotrimoxazole as simply "antibiotic-associated." If diarrhea is severe, persistent, bloody, or accompanied by fever and abdominal pain, immediately consider CDAD and discontinue cotrimoxazole unless treating C. difficile is not feasible 1.

Management Approach

If diarrhea develops on cotrimoxazole:

  1. Assess severity: mild self-limited symptoms vs. signs of CDAD (fever, severe/bloody diarrhea, abdominal pain)
  2. For suspected CDAD: discontinue cotrimoxazole, send stool for C. difficile testing, initiate appropriate fluid/electrolyte management, and consider C. difficile-directed therapy 1
  3. For mild symptoms: consider whether cotrimoxazole is truly necessary or if an alternative agent with fewer GI effects could be substituted
  4. Document the adverse effect for future prescribing decisions

The evidence clearly establishes that gastrointestinal disturbances, including diarrhea, are common with cotrimoxazole, and the serious risk of CDAD warrants careful monitoring of any patient developing diarrhea while on this medication.

Professional Medical Disclaimer

This information is intended for healthcare professionals. Any medical decision-making should rely on clinical judgment and independently verified information. The content provided herein does not replace professional discretion and should be considered supplementary to established clinical guidelines. Healthcare providers should verify all information against primary literature and current practice standards before application in patient care. Dr.Oracle assumes no liability for clinical decisions based on this content.

Have a follow-up question?

Our Medical A.I. is used by practicing medical doctors at top research institutions around the world. Ask any follow up question and get world-class guideline-backed answers instantly.