Articles & Guides › Articles › Infectious Diseases
Opportunistic infections and the immunocompromised host
Which opportunistic infections appear at each CD4 count in HIV and how to tell toxoplasmosis, lymphoma and PML apart, when to give prophylaxis and how immune reconstitution inflammatory syndrome behaves, and how neutropenia, transplantation, asplenia and other immune defects predict which organisms cause infection.
Infectious Diseases · 6 min read · Reviewed 2026-11-10
An opportunistic infection is caused by an organism that a healthy immune system would hold in check. Which organism takes the opportunity depends on which part of the immune system has failed. Losing CD4 T cells exposes a person to organisms that live inside cells and to fungi; losing neutrophils exposes them to bacteria and molds that neutrophils normally destroy; losing antibodies or the spleen exposes them to encapsulated bacteria. In HIV, the CD4 count works like a ladder: as it falls, new infections become possible at predictable thresholds.
Key points
- Below a CD4 count of 200, Pneumocystis pneumonia appears; below 100, cryptococcal meningitis, toxoplasmosis and esophageal candidiasis; below 50, cytomegalovirus retinitis, disseminated Mycobacterium avium complex and CNS lymphoma.
- In advanced HIV, multiple ring-enhancing brain lesions suggest toxoplasmosis, a single lesion suggests lymphoma, and nonenhancing white matter lesions suggest PML.
- Trimethoprim-sulfamethoxazole prevents Pneumocystis below a CD4 count of 200 and toxoplasmosis below 100 in people with Toxoplasma antibodies.
- Immune reconstitution inflammatory syndrome is a paradoxical flare of an infection as immunity recovers on treatment; therapy usually continues.
- Fever with a neutrophil count below 500 needs blood cultures and immediate antipseudomonal antibiotics; people without a spleen are at risk from encapsulated bacteria.
Opportunistic infections by CD4 count
The CD4 ladder
| CD4 count | Infections and conditions |
|---|---|
| Any | Tuberculosis, bacterial pneumonia, shingles, oral thrush, HPV-related cancers, Kaposi sarcoma |
| Below 500 | Oral thrush and oral hairy leukoplakia, white ridged plaques on the side of the tongue caused by Epstein-Barr virus that do not scrape off |
| Below 200 | *Pneumocystis jirovecii* pneumonia: a slowly worsening dry cough and breathlessness, diffuse lung shadows, a raised LDH and oxygen levels that drop on exertion; disseminated histoplasmosis and other endemic fungi[1] |
| Below 100 | Esophageal candidiasis, cryptococcal meningitis (headache with a very high opening pressure, diagnosed by capsular antigen or India ink)[2], toxoplasmosis of the brain[3], chronic diarrhea from Cryptosporidium |
| Below 50 | Cytomegalovirus retinitis (painless vision loss with hemorrhages and exudates on the retina), cytomegalovirus colitis, disseminated *Mycobacterium avium* complex (fever, weight loss, diarrhea, anemia), primary CNS lymphoma, progressive multifocal leukoencephalopathy |
Thrush and oral hairy leukoplakia look alike, but thrush is a Candida coating that scrapes off, while hairy leukoplakia is thickened, virus-infected epithelium that does not.
Brain lesions in advanced HIV
| Feature | Toxoplasmosis | Primary CNS lymphoma | PML |
|---|---|---|---|
| Number | Multiple | Usually single | Several, in white matter |
| Enhancement | Ring-enhancing | Ring or solid enhancement | None |
| Test | Positive Toxoplasma IgG | Epstein-Barr virus DNA in CSF | JC virus DNA in CSF |
| Course | Improves within about two weeks of pyrimethamine and sulfadiazine | Needs lymphoma treatment | Improves only with antiretroviral therapy |
Treating the common ones
Pneumocystis pneumonia is treated with high-dose trimethoprim-sulfamethoxazole for three weeks, adding glucocorticoids when blood oxygen is low, because the burst of inflammation as organisms die can otherwise worsen breathing. Cytomegalovirus retinitis is treated with valganciclovir or ganciclovir, and disseminated Mycobacterium avium complex with a macrolide plus ethambutol. In every case, starting antiretroviral therapy is what ultimately prevents relapse.
For brain lesions, the differences in the table above allow a practical approach that avoids an immediate biopsy: in a patient with multiple ring-enhancing lesions and positive Toxoplasma antibodies, toxoplasmosis treatment is started and the scan repeated; failure to improve points toward lymphoma and biopsy.
Prophylaxis and immune reconstitution
When to give prophylaxis
| CD4 count | Prevents | Drug |
|---|---|---|
| Below 200, or thrush, or an AIDS-defining illness | Pneumocystis | Trimethoprim-sulfamethoxazole; alternatives are dapsone, atovaquone or inhaled pentamidine |
| Below 100 with positive Toxoplasma IgG | Toxoplasmosis | Trimethoprim-sulfamethoxazole, which covers both |
| Below 50 | Mycobacterium avium complex | Weekly azithromycin, often omitted when antiretroviral therapy starts promptly |
| Any count with latent tuberculosis | Tuberculosis | Isoniazid-based or rifamycin-based regimens |
Prophylaxis can stop once antiretroviral therapy has kept the CD4 count above the threshold for three to six months. People with HIV also receive pneumococcal, influenza, hepatitis B and HPV vaccines, and live vaccines are generally avoided below a CD4 count of 200.
Immune reconstitution inflammatory syndrome
Weeks to months after antiretroviral therapy starts, the recovering immune system can suddenly attack an infection that was already present, sometimes one nobody knew about[4]. Lymph nodes swell, fever returns, or a known infection seems to worsen, even though the viral load is falling and the CD4 count rising. This is immune reconstitution inflammatory syndrome (IRIS), not treatment failure. Antiretroviral therapy usually continues, the infection is treated and glucocorticoids are given for severe inflammation.
One exception matters: in cryptococcal meningitis, antiretroviral therapy is delayed for several weeks after antifungal treatment starts, because starting too early raises mortality from inflammation in the brain.
Infections in neutropenia, transplantation and asplenia
Matching the defect to the organism
| Immune defect | Typical infections |
|---|---|
| Neutropenia, especially below 500 | Gram-negative rods including Pseudomonas, gram-positive cocci from catheters, Candida, and molds such as Aspergillus with prolonged neutropenia |
| T cell deficiency (HIV, transplant drugs, steroids) | Pneumocystis, Cryptococcus, cytomegalovirus, mycobacteria, Listeria, Nocardia, Toxoplasma |
| Antibody deficiency (inherited immunodeficiencies, myeloma, rituximab) | Encapsulated bacteria, Giardia |
| Asplenia | Encapsulated bacteria (S. pneumoniae, Hib, N. meningitidis), Capnocytophaga after dog bites, Babesia[5] |
| Terminal complement deficiency | Recurrent Neisseria |
| Chronic granulomatous disease | Catalase-positive organisms such as S. aureus, Serratia, Nocardia and Aspergillus |
Fever with neutropenia
Without neutrophils, infections cannot form pus, so fever may be the only sign. A temperature of 38.3 °C, or a sustained 38.0 °C, with a neutrophil count below 500 is an emergency: blood cultures are drawn and antipseudomonal antibiotics such as cefepime, piperacillin-tazobactam or meropenem are started at once[6]. Vancomycin is added for catheter or skin infection or unstable blood pressure, and antifungal coverage is considered if fever persists for several days.
After organ transplantation
Infections follow a predictable timeline[7]:
| Period | Typical infections |
|---|---|
| First month | Surgical and hospital infections: wound infections, line infections, pneumonia, C. difficile, and infections carried in the donor organ |
| 1 to 6 months, when immunosuppression is strongest | Opportunistic infections: cytomegalovirus, Pneumocystis, Aspergillus, Nocardia, BK virus damage to the kidney, Epstein-Barr virus-driven lymphoma |
| After 6 months | Community infections, late cytomegalovirus and skin cancers |
Transplant recipients usually receive trimethoprim-sulfamethoxazole against Pneumocystis and valganciclovir against cytomegalovirus during the high-risk months.
Common confusions
- Thrush versus oral hairy leukoplakia: thrush scrapes off; hairy leukoplakia, caused by Epstein-Barr virus, does not.
- Toxoplasmosis versus lymphoma versus PML: multiple ring lesions, a single lesion, or nonenhancing white matter disease.
- IRIS versus treatment failure: IRIS comes with a falling viral load and rising CD4 count; failure comes with a persistently high viral load.
- Which defect, which organism: antibody and spleen defects invite encapsulated bacteria; T cell defects invite intracellular organisms and fungi; neutropenia invites gram-negative rods and molds.
References
- Thomas CF Jr, Limper AH. Pneumocystis pneumonia. N Engl J Med. 2004;350(24):2487-2498. doi:10.1056/NEJMra032588 Link ↩
- Perfect JR, Dismukes WE, Dromer F, et al. Clinical practice guidelines for the management of cryptococcal disease: 2010 update by the Infectious Diseases Society of America. Clin Infect Dis. 2010;50(3):291-322. doi:10.1086/649858 Link ↩
- Montoya JG, Liesenfeld O. Toxoplasmosis. Lancet. 2004;363(9425):1965-1976. doi:10.1016/S0140-6736(04)16412-X Link ↩
- Müller M, Wandel S, Colebunders R, et al. Immune reconstitution inflammatory syndrome in patients starting antiretroviral therapy for HIV infection: a systematic review and meta-analysis. Lancet Infect Dis. 2010;10(4):251-261. doi:10.1016/S1473-3099(10)70026-8 Link ↩
- Rubin LG, Schaffner W. Care of the asplenic patient. N Engl J Med. 2014;371(4):349-356. doi:10.1056/NEJMcp1314291 Link ↩
- Freifeld AG, Bow EJ, Sepkowitz KA, et al. Clinical practice guideline for the use of antimicrobial agents in neutropenic patients with cancer: 2010 update by the Infectious Diseases Society of America. Clin Infect Dis. 2011;52(4):e56-e93. doi:10.1093/cid/cir073 Link ↩
- Fishman JA. Infection in organ transplantation. Am J Transplant. 2017;17(4):856-879. doi:10.1111/ajt.14208 Link ↩