The relation between climate change and human health has become one of the major worldwide public health issues. However, the evidence for low-latitude plateau regions is limited, where the climate is unique and diverse with a complex geography and topography. This study aimed to evaluate the effect of ambient temperature on the mortality burden of nonaccidental deaths in Yunnan Province and to further explore its spatial heterogeneity among different regions. We collected mortality and meteorological data from all 129 counties in Yunnan Province from 2014 to 2020, and 16 prefecture-level cities were analyzed as units. A distributed lagged nonlinear model was used to estimate the effect of temperature exposure on years of life lost (YLL) for nonaccidental deaths in each prefecture-level city. The attributable fraction of YLL due to ambient temperature was calculated. A multivariate meta-analysis was used to obtain an overall aggregated estimate of effects, and spatial heterogeneity among 16 prefecture-level cities was evaluated by adjusting the city-specific geographical characteristics, demographic characteristics, economic factors, and health resources factors. The temperature-YLL association was nonlinear and followed slide-shaped curves in all regions. The cumulative cold and heat effect estimates along lag 0-21 days on YLL for nonaccidental deaths were 403.16 (95% empirical confidence interval [eCI] 148.14-615.18) and 247.83 (95% eCI 45.73-418.85), respectively. The attributable fraction for nonaccidental mortality due to daily mean temperature was 7.45% (95% eCI 3.73%-10.38%). Cold temperature was responsible for most of the mortality burden (4.61%, 95% eCI 1.70-7.04), whereas the burden due to heat was 2.84% (95% eCI 0.58-4.83). The vulnerable subpopulations include male individuals, people aged <75 years, people with education below junior college level, farmers, nonmarried individuals, and ethnic minorities. In the cause-specific subgroup analysis, the total attributable fraction (%) for mean temperature was 13.97% (95% eCI 6.70-14.02) for heart disease, 11.12% (95% eCI 2.52-16.82) for respiratory disease, 10.85% (95% eCI 6.70-14.02) for cardiovascular disease, and 10.13% (95% eCI 6.03-13.18) for stroke. The attributable risk of cold effect for cardiovascular disease was higher than that for respiratory disease cause of death (9.71% vs 4.54%). Furthermore, we found 48.2% heterogeneity in the effect of mean temperature on YLL after considering the inherent characteristics of the 16 prefecture-level cities, with urbanization rate accounting for the highest proportion of heterogeneity (15.7%) among urban characteristics. This study suggests that the cold effect dominated the total effect of temperature on mortality burden in Yunnan Province, and its effect was heterogeneous among different regions, which provides a basis for spatial planning and health policy formulation for disease prevention.