Cancer remains a significant burden for human immunodeficiency virus (HIV)-infected individuals. Most cancers that are associated with HIV infection are driven by oncogenic viruses, such as Epstein-Barr virus, Kaposi's sarcoma-associated herpesvirus and human papillomavirus. Gaining insight into the epidemiology and mechanisms that underlie AIDS-related cancers has provided us with a better understanding of cancer immunity and viral oncogenesis.