(1) To determine the prevalence of HIV-1 and HIV-2 infections and associated risk factors in men attending Abidjan's three sexually transmitted disease (STD) clinics; (2) to examine the use of such sites for epidemiological surveillance. Cross-sectional study. Abidjan's two main STD clinics (Clinics A and T), and the University Hospital Dermatology outpatients clinic. Consecutive patients with genitourinary symptoms. Prevalence of reactivity to HIV-1, HIV-2, and both viruses; descriptive characteristics of clinic attenders; clinical diagnoses of STD; risk factors associated with HIV-1 and HIV-2 positivity. The overall prevalence of HIV (HIV-1 and/or HIV-2) infection was 21% (250 out of 1169; 16% HIV-1, 2% HIV-2, 3% dual reactivity). Overall prevalence varied by clinic: University Hospital Dermatology outpatients clinic, 39%; Clinic T, 19%; Clinic A, 10%. Men with STD had an overall prevalence of 31% (155 out of 506), compared with 14% in men without physical signs of STD (odds ratio 2.6, 95% confidence interval 2.0-3.6). The highest prevalence, 46%, was in men with genital ulcer disease. Risk factors associated with HIV-1 as well as with HIV-2 infection after multivariate analysis were a history of sex with prostitutes, lack of circumcision, being unskilled, and a history of prior genital ulcer. Current genital ulcer, current STD and positive Treponema pallidum haemagluttination assay were associated with HIV-1 and dual reactivity. Risk factors for HIV-2 infection in men attending Abidjan STD clinics were broadly similar to those for HIV-1 infection. HIV-1 infection was more strongly associated with current STD. Important differences between the three clinics were observed in STD prevalence and type, and HIV seroprevalence. Such differences should be taken into account in the planning of HIV serosurveillance in STD clinics.