Worldwide, more than three million children are infected with HIV, 90% of whom live in sub-Saharan Africa. As the HIV epidemic matures and antiretroviral treatment is scaled up, children with HIV are reaching adolescence in large numbers. The growing population of adolescents with perinatally acquired HIV infection living within this region presents not only unprecedented challenges but also opportunities to learn about the pathogenesis of HIV infection. In this Review, we discuss the changing epidemiology of paediatric HIV and the particular features of HIV infection in adolescents in sub-Saharan Africa. Longstanding HIV infection acquired when the immune system is not developed results in distinctive chronic clinical complications that cause severe morbidity. As well as dealing with chronic illness, HIV-infected adolescents have to confront psychosocial issues, maintain adherence to drugs, and learn to negotiate sexual relationships, while undergoing rapid physical and psychological development. Context-specific strategies for early identification of HIV infection in children and prompt linkage to care need to be developed. Clinical HIV care should integrate age-appropriate sexual and reproductive health and psychological, educational, and social services. Health-care workers will need to be trained to recognise and manage the needs of these young people so that the increasing numbers of children surviving to adolescence can access quality care beyond specialist services at low-level health-care facilities.