The dominant spatial econometric model in spatial econometrics is the parametric form, while in the realistic context, the variables often do not satisfy the assumption of linearity and have nonlinear relationships with each other. In this paper, we introduce nonparametric terms into spatial econometric models and propose the MCMCINLA estimation method for varying coefficient spatial lag models. The empirical analysis is conducted with the socioeconomic data of mainland China from 2015 to 2020 to discuss the influencing factors and spatial and temporal distribution characteristics of China’s economic development under the classical spatial lag model and the varying coefficient spatial lag model with population aging as a special covariate, respectively. The results show that with the gradual aging of the population, foreign trade will inhibit the development of regional economy to a certain extent, while urbanization process, resident income, real estate development and high-tech development will have a driving effect on economic growth, and high-tech development has the strongest mobilization on regional economic development. Compared with the classical spatial lag model, the varying coefficient spatial lag model can more fully exploit the information of variables in a more realistic context and derive the variable evolution process.