Accelerated urbanization has made the disaster situation increasingly severe, especially that related to geological disasters, floods, fires, and other disasters. In response to high-frequency disasters, external disaster prevention spaces, mainly urban green spaces, play a key role in sheltering and housing. While many current studies focus on the balanced layout of green space, which improves their disaster prevention and avoidance capacity to a certain extent, there is insufficient consideration of disaster distribution and population demand, leading to conflicts between green space supply and demand. Therefore, this study further explores the efficiency improvement of disaster-prevention and risk-avoidance green space (DPRAGS) from the perspective of matching supply and demand. Taking the main urban area of Nanjing as an example, we rely on ArcGIS, combined with the maximum capacity limitation coverage model, and conduct green space layout analysis through analysis of urban infrastructure, disaster risk, and the demand and supply of DPRAGS. The research results show that compared with previous green space planning methods involving suitability assessment and accessibility analysis, the unitized planning method, mainly based on supply and demand matching, can better meet the refuge requirements of demand points and improve the rationality of green space layout. This study enriches the theory of urban green space planning and guides the planning of DPRAGS in typical densely populated metropolises, such as Nanjing. Additionally, it can help develop emergency plans and management rules and regulations, ultimately enhancing evacuation efficiency during disasters and improving overall urban disaster prevention and emergency management capabilities.