To determine the prevalence of anogenital warts (AGWs) and concurrent sexually transmitted infections (STIs) in men who have sex with men (MSM), and their knowledge of human papillomavirus (HPV). Attitudes towards the HPV vaccine among MSM are explored. A web-based cross-sectional survey on AGWs, sociodemographic factors and sexual behaviour conducted in August 2009 in Denmark. Overall 25.2% of the 1184 respondents reported a prior or current episode of AGWs. The prevalence of AGW was significantly higher in homosexuals compared with bisexuals, in men with high levels of education and in those with a high number of sexual partners within the last year. MSM with a history of another STI reported a significantly higher prevalence of warts. More than 70% did not know what causes AGWs. If a free HPV vaccine were to be offered, 94.4% would like to receive it. These data suggest a high prevalence of AGWs in Danish MSM. The awareness of HPV is low; however, the acceptance of a HPV vaccine seems high.