Enhancing urban ecological welfare performance is essential for achieving sustainable urban development and fostering a comprehensive regional green transformation. This study develops a quantitative assessment framework for urban ecological welfare performance, grounded in both the welfare of urban residents and their consumption of ecological resources. Employing the spatio-temporal Logarithmic Mean Divisia Index model to dissect the ecological welfare performance across 108 key prefecture-level cities within China’s Yangtze River Economic Belt, considering both temporal and spatial dimensions, the analysis reveals a “W”-shaped trajectory in the ecological welfare performance from 2006 to 2022, characterized by pronounced spatial disparities. Particularly in the downstream coastal regions and notably the Yangtze River Delta, advantages in social and economic structures, along with public fiscal outlays, contribute to a superior ecological welfare performance, exhibiting a notable spatial spillover effect. The study introduces six key factors—social benefit, economic benefit, population dispersion, population density in urban areas, urbanization scale, and ecological sustainability—to examine their influence on ecological welfare performance, uncovering substantial differences in the outcomes of temporal and spatial decomposition. Temporal decomposition indicates that economic benefit and urbanization scale are the primary drivers enhancing ecological welfare performance, whereas population dispersion is identified as the primary inhibitor. Spatial decomposition reveals that the determinants of above-average urban ecological welfare vary regionally and undergo dynamic shifts over time. Overall, a holistic understanding of the interplay among economic growth, ecological preservation, and the enhancement of residents’ welfare can inform the development and execution of tailored policies by local governments.