Two independent studies were undertaken to determine the effect of prophylactic treatment with aerosolized pentamidine on the laboratory diagnosis of Pneumocystis carinii pneumonia in individuals at risk for or with the acquired immunodeficiency syndrome. The first study was a retrospective analysis to determine the effect of prophylactic treatment with aerosolized pentamidine on the diagnostic yield and sensitivity of detection of P carinii in induced sputum specimens. The results of examinations of 110 induced sputum specimens from patients who had not received aerosolized pentamidine were compared with the findings in 57 specimens from patients who had. There was no statistically significant difference between the two groups for the diagnostic yield in induced sputum specimens (48% vs 47%) or in bronchoalveolar lavage fluid specimens subsequently obtained from patients with nondiagnostic induced sputum examinations (33% vs 37%). The sensitivity of induced sputum specimens for identifying P carinii was 76% to 78% for patients who had not received aerosolized pentamidine and 71% to 75% for patients who had received the drug. The second study was a prospective comparison of 118 bronchoalveolar lavage fluid specimens to determine the effect of prophylactic treatment with aerosolized pentamidine on the number of organisms present. One hundred eighteen bronchoalveolar lavage fluid specimens were quantitatively examined and scored according to the number of clumps of P carinii present. No statistically significant difference was seen in the number of clumps of P carinii found in specimens from patients who had received aerosolized pentamidine vs the number of clumps found in specimens from patients who had not. In conclusion, prophylactic treatment with aerosolized pentamidine had no effect on (1) the diagnostic yield and sensitivity of detection of P carinii in induced sputum specimens or (2) the number of organisms detected in bronchoalveolar lavage fluid specimens obtained from individuals at risk for or with the acquired immunodeficiency syndrome.