Ecosystem restoration has the potential to improve the ecological environment, increase ecosystem service delivery capability, and promote biodiversity conservation. Although Habitat quality (HQ) is being widely used as a metric for large-scale biodiversity conservation, it is poorly understood and measured in areas with significant vegetation restoration. This study proposes a modified approach based on the InVEST-HQ module by coupling Normalized Difference Vegetation Index (NDVI) to measure the HQ in the Yellow River Basin (YRB) with extensive vegetation restoration in recent decades. The results show that the vegetation restoration area with significant increases in both Leaf Area Index (LAI) and Net Primary Production (NPP) accounts for 29.7% of the total area of the YRB. The original and modified modules were compared. Based on the InVEST-HQ module, the results show that HQ has a tendency for very small changes in the years 2000, 2010, and 2020, with first a small increase and then a small decrease; however, habitat quality based on the modified method has a significantly increasing trend, which is consistent with the ecological restoration status of the study area and the trend of key ecosystem parameters. The modified method effectively expresses habitat quality changes with vegetation restoration, making it more appropriate for usage in areas where nature conservation and ecosystem restoration are important management actions, allowing for realistic decision-making and data support for regional biodiversity conservation and habitat management.