Objective: To analyze how patterns of excess mortality varied by sex and age groups across countries during the COVID-19 pandemic and their association with country income level. Methods: We used World Health Organization excess mortality estimates by sex and age groups for 75 countries in 2020 and 62 countries in 2021, restricting the sample to estimates based on recorded all-cause mortality data. We examined patterns across countries using country-specific Poisson regressions with observations consisting of the number of excess deaths by groups defined by sex and age. Findings: Men die at higher rates in nearly all places and at all ages beyond age 45. In 2020, the pandemic amplified this gender mortality gap for the world, but with variation across countries and by country income level. In high-income countries, rates of excess mortality were much higher for men than women. In contrast, in middle-income countries, the sex ratio of excess mortality was similar to the sex ratio of expected all-cause mortality. The exacerbation of the sex ratio of excess mortality observed in 2020 in high-income countries, however, declined in 2021. Conclusion: The COVID-19 pandemic has killed men at much higher rates than women, as has been well documented, but these gender differences have varied by country income. These differences were the result of some combination of variation in gender patterns of infection rates and infection fatality rates across countries. The gender gap in mortality declined in high-income countries in 2021, likely as a result of the faster rollout of vaccination against COVID-19.