Natural revegetation has been widely confirmed to be an effective strategy for the restoration of degraded lands, particularly in terms of rehabilitating ecosystem productivity and soil nutrients. Yet the mechanisms of how natural revegetation influences the variabilities and drivers of soil residing fungal communities, and its downstream effects on ecosystem nutrient cycling are not well understood. For this study, we investigated changes in soil fungal communities along with ~160 years of natural revegetation in the Loess Plateau of China, employing Illumina MiSeq DNA sequencing analyses. Our results revealed that the soil fungal abundance was greatly enhanced during the later stages of revegetation. As revegetation progresses, soil fungal richness appeared first to rise and then decline at the climax Quercus liaotungensis forest stage. The fungal Shannon and Simpson diversity indexes were the lowest and highest at the climax forest stage among revegetation stages, respectively. Principal component analysis, Bray–Curtis similarity indices, and FUNGuild function prediction suggested that the composition, trophic modes, and functional groups for soil fungal communities gradually shifted along with natural revegetation. Specifically, the relative abundances of Basidiomycota, Agaricomycetes, Eurotiomycetes, and ectomycorrhizal fungi progressively increased, while that of Ascomycota, Sordariomycetes, Dothideomycetes, Tremellomycetes, saprotrophic, pathotrophic, arbuscular mycorrhizal fungi, and endophyte fungi gradually decreased along with natural revegetation, respectively. The most enriched members of Basidiomycota (e.g., Agaricomycetes, Agaricales, Cortinariaceae, Cortinarius, Sebacinales, Sebacinaceae, Tricholomataceae, Tricholoma, Russulales, and Russulaceae) were found at the climax forest stage. As important carbon (C) sources, the most enriched symbiotic fungi (particularly ectomycorrhizal fungi containing more recalcitrant compounds) can promote organic C and nitrogen (N) accumulation in soils of climax forest. However, the most abundant of saprotrophic fungi in the early stages of revegetation decreased soil organic C and N accumulation by expediting the decomposition of soil organic matter. Our results suggest that natural revegetation can effectively restore soil fungal abundance, and modify soil fungal diversity, community composition, trophic modes, and functional groups by altering plant properties (e.g., plant species richness, diversity, evenness, litter quantity and quality), quantity and quality of soil nutrient substrates, soil moisture and pH. These changes in soil fungal communities, particularly their trophic modes and functional groups along with natural revegetation, impact the accumulation and decomposition of soil C and N and potentially affect ecosystem C and N cycling in the Loess Plateau of China.