What infections can lead to male infertility and how are they treated?

Let's get one thing straight right away: infertility is not a character flaw, and it's not a verdict on your masculinity. It's a medical condition. And like many medical conditions, some causes are reversible-especially when infections are the root.

Infections are a surprisingly common and often overlooked cause of male fertility problems. They can damage sperm directly, block the plumbing, or trigger an immune response that attacks your own swimmers. The good news is that many of these are treatable, and if caught early, the damage can be limited or reversed.

Here's what you need to know about the infections that affect male fertility, how they cause trouble, and what treatment looks like.

How an infection messes with fertility

Infections can impair male fertility through three main mechanisms:

  • Direct damage to sperm production. Some infections inflame the testicles themselves (orchitis), which can temporarily or permanently reduce sperm output.
  • Blockage of the reproductive tract. Infections can cause scarring in the epididymis, vas deferens, or ejaculatory ducts, stopping sperm from getting into semen.
  • Immune system confusion. The body may produce anti-sperm antibodies after an infection, tagging sperm as foreign invaders and immobilizing them.

Each of these pathways responds differently to treatment, so knowing which one you're dealing with matters.

The infections most commonly linked to male infertility

1. Chlamydia trachomatis and Neisseria gonorrhoeae (STIs)

These two bacterial infections are the most common sexually transmitted infections worldwide. In men, they often cause urethritis (inflammation of the urethra). If untreated, the infection can travel up the reproductive tract and cause epididymitis (inflammation of the epididymis, the tube where sperm mature).

A 2017 review in Human Reproduction Update found that chlamydia and gonorrhea infections are associated with reduced sperm motility and increased DNA fragmentation in sperm. The scarring they cause can also physically block sperm transport.

Treatment: Both are treated with antibiotics. Chlamydia responds to azithromycin or doxycycline. Gonorrhea is typically treated with ceftriaxone. The key is early treatment. Once scarring has formed, antibiotics won't reverse it. That's why regular STI screening matters if you're sexually active with multiple partners or have had unprotected sex.

2. Mumps orchitis

This one is a classic. Mumps is a viral infection, and in post-pubertal males (after puberty), about 20-30% of cases involve the testicles. The virus causes swelling and inflammation of one or both testicles. The damage is usually to the seminiferous tubules-the actual sperm factories.

A 2012 study in the Journal of Andrology followed 50 men with mumps orchitis. About 60% had reduced sperm counts six months after infection. In severe cases, the damage can be permanent, especially if both testicles are affected.

Treatment: There is no antiviral for mumps. Treatment is supportive-rest, ice, anti-inflammatory drugs like ibuprofen, and sometimes corticosteroids to reduce swelling. The MMR vaccine is highly effective at preventing mumps entirely. If you weren't vaccinated as a child, talk to your doctor about getting it now.

3. Prostatitis (bacterial and chronic)

The prostate sits right below the bladder and produces fluid that makes up a significant portion of semen. Bacterial prostatitis can cause inflammation that changes the pH and chemical composition of seminal fluid, making it hostile to sperm. Chronic prostatitis (often non-bacterial) can also cause pelvic pain and erectile dysfunction, which indirectly affects fertility.

A 2019 meta-analysis in Fertility and Sterility found that men with chronic prostatitis had significantly lower sperm concentration and motility compared to healthy controls. The inflammation itself, not just the bacteria, seems to be the culprit.

Treatment: Acute bacterial prostatitis is treated with a course of antibiotics (typically fluoroquinolones like ciprofloxacin or doxycycline for 4-6 weeks). Chronic prostatitis is trickier. If no bacteria are found, treatment focuses on reducing inflammation with anti-inflammatory drugs, alpha-blockers to relax the prostate, and physical therapy for pelvic floor tension. Lifestyle changes-avoiding prolonged sitting, staying hydrated, and ejaculating regularly-can also help.

4. Epididymitis (from E. coli or other enteric bacteria)

Not all epididymitis is STI-related. In men over 35 or those with urinary tract issues, the bacteria that cause epididymitis are often from the gut (E. coli, Klebsiella, Pseudomonas). These infections can cause swelling, pain, and scarring in the epididymis.

Treatment: Antibiotics tailored to the specific bacteria. A urine culture helps identify the pathogen. Rest, scrotal support, and anti-inflammatories are also part of the standard protocol.

5. Tuberculosis (genitourinary TB)

This is less common in developed countries but still a significant cause of male infertility in regions where TB is endemic. Genitourinary TB can infect the epididymis, prostate, and seminal vesicles, causing extensive scarring and obstruction. It often goes unnoticed because the symptoms can be mild or absent.

Treatment: A multi-drug antibiotic regimen for 6-9 months. The scarring is usually permanent, so treatment aims to prevent further damage rather than reverse existing blockages.

6. HIV

HIV itself doesn't directly cause infertility, but the medications used to manage it can affect sperm quality. More importantly, HIV can cause hypogonadism (low testosterone) due to its effects on the endocrine system. A 2015 study in AIDS found that men with HIV had lower sperm motility and higher DNA fragmentation than HIV-negative men, even when viral loads were undetectable.

Treatment: Antiretroviral therapy (ART) is the standard. If low testosterone is present, some men benefit from testosterone replacement (under a doctor's supervision). Sperm banking is often recommended before starting ART if fertility is a concern.

How do you know if an infection is affecting your fertility?

Most of these infections cause symptoms-pain, discharge, swelling, fever-but not always. Asymptomatic infections are common, especially with chlamydia. That's why a semen analysis is part of the standard fertility workup. A semen culture can identify bacteria in the semen, and a physical exam can reveal swollen epididymides or a tender prostate.

If you have any of these symptoms, see a doctor:

  • Pain or swelling in the testicles
  • Burning during urination or ejaculation
  • Unusual discharge from the penis
  • Pain in the lower abdomen or perineum (the area between the scrotum and anus)
  • Unexplained fever or chills

And if you're trying to conceive and haven't had a fertility checkup, a semen analysis is a simple, non-invasive first step.

Treatment principles: what actually works

  1. Antibiotics when indicated. If a bacterial infection is confirmed, a full course of the right antibiotic is the priority. Do not stop early, even if symptoms resolve. Incomplete treatment can lead to antibiotic resistance and chronic inflammation.
  2. Anti-inflammatories. Even after the infection clears, inflammation can persist. NSAIDs like ibuprofen or naproxen can help reduce swelling and protect sperm production during recovery.
  3. Scrotal support and rest. For acute epididymitis or orchitis, supporting the testicles and avoiding heavy lifting or prolonged standing helps reduce pain and swelling.
  4. Surgical intervention if needed. If an infection has caused a blockage (like a vas deferens obstruction), a urologist may recommend microsurgical reconstruction to restore sperm flow. This is usually done after the infection is fully cleared.
  5. Fertility preservation. If you're about to start treatment for an infection that might affect fertility (like mumps orchitis or TB), consider sperm banking. It's a one-time investment that gives you options later.

What about prevention?

You can't prevent every infection, but you can reduce your risk:

  • Get vaccinated. The MMR vaccine prevents mumps. The HPV vaccine prevents genital warts and some cancers. Both are safe and effective.
  • Use condoms.
Get the Sauna Playbook