Background: Kaposi sarcoma is a rare, possibly angioproliferative, tumour. Kaposi sarcoma is one of the most common cancers in people living with HIV and poses a serious public health challenge in regions with high HIV burden. We aim to describe global patterns and population-wide trends in the burden of Kaposi sarcoma. Methods: In this population-based study, the incidence and mortality estimates of Kaposi sarcoma from 185 countries and regions in 2020 were extracted from the GLOBOCAN 2020 database. The time trends in Kaposi sarcoma incidence were evaluated using the cancer registry data from Cancer Incidence in Five Continents plus from 1998 to 2012. We did not apply any inclusion or exclusion criteria to the data used in this study. Joinpoint regression was used to evaluate the average annual percentage change (AAPC) to quantify trends in the age-standardised incidence rate (ASIR) of Kaposi sarcoma. Correlation analysis was used to evaluate the relationship between the ASIR or age-standardised mortality rate (ASMR) and Human Development Index (HDI). Findings: In 2020, the global estimated ASIR of Kaposi sarcoma was 0·39 (per 100 000 people), with an estimated 34 270 newly diagnosed cases (23 413 males and 10 857 females). An estimated 15 086 Kaposi sarcoma deaths were reported (9929 males and 5157 females), corresponding to an ASMR of 0·18 (per 100 000 people). In 2020, Africa accounted for 73·0% (25 010 of 34 270) of the incidence and 86·6% (13 066 of 15 086) of the deaths from Kaposi sarcoma worldwide. There was a significant correlation between the ASIR or ASMR and HDI. The incidence of Kaposi sarcoma increased in males in both Türkiye and the Netherlands. The AAPC was 11·5% (95% CI 3·2–20·4) for males in Türkiye and 2·5% (1·1–3·9) for males in the Netherlands from 1998 to 2012. The incidence of Kaposi sarcoma decreased in White Americans, Israel, Uganda, Costa Rica, Colombia, Canada, and Denmark, from 1998 to 2012. Interpretation: Kaposi sarcoma is a relatively rare cancer worldwide but is endemic in some countries in southern and eastern Africa. Addressing disparities in health-care resource allocation and improving HIV/AIDS care across different HDI regions might contribute to the prevention of Kaposi sarcoma.