What are the characteristics of HIV transmission that allow us to optimise prevention? How do they vary by setting and over time? The PANGEA-HIV consortium — described here www.pangea-hiv.org — was set up to investigate this using HIV virus genomics, epidemiology and behavioural science. >90% of virus genomes available from Southern and Eastern Africa were generated by PANGEA, working in underserved populations with very high HIV infection rates. The consortium brings together experts in six leading African centres working alongside epidemiologists, behavioural scientists and ethicists in the UK and USA. We are generating evidence that shapes HIV prevention programmes. I will describe multidisciplinary investigations and trials that assess the increasing impact that treatment has in preventing transmission. Antiretroviral therapy has been the cornerstone, but other factors influence. Progress has been fast enough that UNAIDS has declared that on current pace, ‘AIDS will end as a public health threat’ by 2030. Several countries have already met the goals set for 2030. And yet, treatment will be needed for decades, and many new infections will arise. I will describe what we are learning about the changing patterns of infection and prevention, looking towards 2030 and beyond.