The widely distributed karst ecosystem in China has experienced rapid deterioration by deforestation and intensive cultivation in the last 50 years. Under the “Grain for Green” program, disturbed croplands were progressively abandoned to restore soil functions and ecosystem services, observed as discrete vegetation recovery phases: cultivated land, abandoned land and secondary forest, and compared to natural primary forest. Karst soils are naturally poor in nitrogen and cessation of nitrogen fertilizer application after abandonment presents an opportunity to explore the reemergence of indigenous soil N2 fixation mechanisms. In this study, we investigated how vegetation recovery affects key soil properties and their relationships with free-living N2 fixation (FLNF) activity and nifH gene abundance, microbial community structure and network interactions at different soil depths from the surface to the rock-soil interface at the bottom of the soil profile. Soil FLNF activity was increased slightly but not significantly after abandonment and was greatest in primary forest soils. High levels of FLNF activity in primary forest soils was facilitated directly by larger total organic carbon to total nitrogen ratios and an altered free-living diazotrophic community composition that was mainly modified by soil moisture content and pH. Higher FLNF was identified at rock-soil interfaces compared to topsoils, which was mainly driven by altered diazotrophic community composition stimulated by increases in soil pH and dissolved organic carbon to available inorganic nitrogen ratios. Diazotrophic network interactions also contributed to variations in FLNF activity, with relatively stable and competitive, while less niche-separated, diazotrophic communities supporting high FLNF activity in primary forest soils, while complex and mutualistic interactions facilitated the high FLNF at rock-soil interfaces. These results suggest that there is considerable and persistent FLNF in degraded karst landscapes at rock-soil interfaces which enables the provision of a vital biological source of nitrogen to overcome the nutrient limitations of karst rock weathering at the bottom of the soil profile.