Respiratory tract specimens, 75 bronchoalveolar lavage (BAL) samples and 19 throat swabs from 75 hospitalized adult patients (of whom 55 were seropositive for human immunodeficiency virus) with pulmonary infiltrates, were examined for Mycoplasma pneumoniae and Mycoplasma genitalium by culture and polymerase chain reaction (PCR). Urogenital specimens (103 from 48 male patients with nongonococcal urethritis and 55 female patients with genital infections) were examined for M. genitalium by the same techniques. Cultures of all the samples were negative. The oligonucleotides were chosen from the published nucleotide sequences of the P1 adhesin gene from M. pneumoniae or the MgPa adhesin gene from M. genitalium. The products of PCR were identified by restriction analysis and hybridization. Results of PCR for respiratory specimens were positive for the following mycoplasmas: M. pneumoniae (3 specimens), M. genitalium (1), and both M. pneumoniae and M. genitalium (3). PCR results for eight urogenital samples from male patients were positive for M. genitalium. Differences concerning the restriction sites were observed between respiratory and genital specimens. The major findings of this study are the presence of DNA from M. pneumoniae in respiratory specimens from patients for whom cultures were negative and DNA from M. genitalium in respiratory and urogenital samples.