In the past decades, rapid urbanization in China has dramatically transformed natural spaces into construction land, leading to serious degradation and supply-demand imbalance of ecosystem services (ESs). The identification of critical areas and ecological security patterns is crucial for balancing ESs and improving human well-being in rapidly urbanized regions. The purpose of this study was to establish a comprehensive assessment framework of ES supply-demand including provisioning, regulating, supporting, and cultural services, so as to provide theoretical support for the identification and refined management of regional critical areas. Taking a typical waterside area in Shanghai metropolitan area as an example, based on multi-source data and ES quantitative models, we used ecological supply-demand ratio and bivariate local indicators of spatial association to quantify the relationship and matching patterns of ES supply-demand, then explored the identification, protection, and restoration of ecologically critical areas at the regional scale. The results showed that: 1) the ES supply-demand relationship in the study area was quantitatively determined. The ecological supply-demand ratio was as follows: regulating > provisioning > supporting > cultural, in which the supply of supporting and cultural services was less than the demand, and the problem of the supply-demand mismatch is prominent; 2) we have identified 41 supply critical areas that require priority protection, with a total area of 206.79 km(2) accounting for 9.65% of the total study area, showing a spatial pattern of more in the northwest and less in the southeast; 3) a total of 11 demand critical areas that need ecological restoration were identified, accounting for 31.43% of the 35 administrative towns in the study area, which are mainly distributed around three urban centers and a high-tech zone. The study is of great significance for the construction of regional ecological security patterns and rational ES allocation, and can provide a scientific framework for the ecological protection and restoration of critical areas around metropolises in developing countries.