The central Yunnan urban agglomeration represents a typical urban cluster in the southwestern region of China. The swift urbanization and land use changes in this region pose a severe threat to the ecosystem. A thorough assessment of the landscape ecological risk in the central Yunnan urban agglomeration holds paramount importance for devising effective risk management strategies and sustainable, high-quality development plans. This study utilizes long-term land-use raster data for six time periods (1995, 2000, 2005, 2010, 2015, and 2020) in the Central Yunnan urban agglomeration. Using GIS technology, a landscape risk index model is constructed, and a comprehensive assessment of landscape ecological risks in the Central Yunnan urban agglomeration is conducted using the 5 km × 5 km grid analysis method and Kriging interpolation. The results indicate that, between 1995 and 2020, the Central Yunnan urban agglomeration was dominated by forest land, grassland, and cultivated land as the primary land-use types. Forest land covered over 48% of the total area, while grassland and cultivated land accounted for more than 26% and 18%, respectively. Notably, construction land underwent a significant increase, mainly due to conversions from cultivated land, forest land, and grassland. Over a span of 25 years, the study area has experienced a continual rise in landscape ecological risk. The landscape ecological risk was mainly characterized by medium, higher, and high ecological risk. Grassland predominated in areas with medium levels of ecological risk, while cultivated land and construction land were predominant in regions with higher and high levels of ecological risk. Spatially, regions with lower ecological risk were primarily distributed in the Chuxiong Yi Autonomous Prefecture, whereas areas with higher and high levels of ecological risk were concentrated in Qujing City and Kunming City. The spatial aggregation patterns of landscape ecological risk in the Central Yunnan urban agglomeration featured “high–high” (H–H) and “low–low” (L–L) clusters, both displaying an initial increase followed by a decrease. The primary factors contributing to the rise in the landscape ecological risk index were identified as urban expansion, population growth, ecological fragmentation, and vegetation destruction. The study’s outcomes can offer valuable insights for optimizing land resources and promoting sustainable development in the Central Yunnan urban agglomeration.