In the context of the era of common prosperity, this paper seeks to explore the influence of human capital on the urban-rural income gap in China. To accomplish this, this paper utilizes panel data encompassing 31 provincial-level administrative regions spanning the years 2000 to 2019. Employing a combination of econometric techniques, including 2SLS, Difference-in-difference models, moderating effects models, and the spatial Durbin model, this paper investigates various facets of human capital and its impact on the urban-rural income gap. The key findings of this paper are as follows: (1) The relationship between human capital and the urban-rural income gap exhibits a U-shaped pattern. (2) The college enrollment expansion policy leads to the widening of the urban-rural income gap in China driven by factors related to the scale, quality, and inequality within higher education. (3) The digital economy plays a positive moderating role in the U-shaped relationship between human capital and the urban-rural income gap. (4) Human capital's impact on the urban-rural income gap demonstrates a significant spatial correlation, displaying a U-shaped spatial spillover effect. Drawing from the aforementioned findings, this paper offers valuable policy implications to guide policymakers in their efforts to foster the attainment of common prosperity.