AIDS-related Kaposi's sarcoma (KS) is a unique model of the relationship between viral infection, immunity, environmental, and genetic factors in viral cancers. The goal was to determine the distribution of KS cases among Brazilian geopolitical regions, looking at the ecological relationship with median CD4 cell count. Ecological study using Brazilian National Diseases Reporting Databases: 1982-2009. Subjects ≥ 13 years of age who have KS cited in their AIDS reporting form were selected, and demographic and HIV exposure data were collected. We found 11,731 KS cases in the period, with a prevalence of 2.4% among AIDS cases; 88% were male, and 68% lived in the Southeast region, which accounted for 59% of AIDS cases. The regional and national prevalence trends were similar, although the highest proportion among women was found in the North region, which has the lowest number of both AIDS and KS cases. Heterosexual transmission accounted for 87% of HIV among women compared to 18% among men. Fifty-seven percent of all KS cases were diagnosed before antiretroviral therapy (ART). Injection drug use accounted for 11% of KS cases. Median survival was 472 days before the ART era and 1482 after it (P < 0.001). Median CD4 counts increased in all regions in the period as ART coverage expanded, and a resulting correlating decline in KS cases was observed. Prevalence of KS declined after the introduction of ART in all regions of Brazil, suggesting individual protection conveyed by ART.