Objectives: To assess the prevalence of sexually transmitted infections (STIs), the frequency of sexual risk behaviours, and the relation between knowledge of HIV infection status and sexual risk behaviour among men who have sex with men (MSM) infected with HIV attending an STI clinic in Peru. Methods: We recruited a convenience sample of 559 MSM from a municipal STI clinic in Lima, Peru. Participants completed a survey and provided blood for HIV, syphilis and HSV-2 antibody testing, and urine for gonorrhoea and chlamydia nucleic acid testing. Results: Among 124 MSM with HIV, 72.6% were aware that they were infected with HIV. Active syphilis (RPR≥=1:8) was diagnosed in 21.0% of men infected with HIV, HSV-2 in 79.8%, urethral gonorrhoea in 1.6% and chlamydia in 1.6%. Among 41 participants reporting insertive anal intercourse with their last sex partner, 34.2% did not use a condom. Of the 86 participants reporting receptive anal intercourse, 25.6% did not use a condom. At least one episode of insertive unprotected anal intercourse (UAI) with a partner uninfected with HIV during the past 6 months was reported by 33.6% (35/104) of participants, and receptive UAI with a partner uninfected by HIV was reported by 44.6% (45/101). There was no difference in frequency of UAI with partners infected or uninfected with HIV observed between men who knew their serostatus compared with those who were previously undiagnosed (all p values >0.05). Conclusions: MSM with HIV in Peru engaged in high-risk behaviours for spreading HIV and STIs. Knowledge of whether someone was infected with HIV was not associated with a decreased frequency of UAI. Additional efforts to reduce risk behaviour after the diagnosis of HIV infection are necessary.