In the critical period of strengthening the construction of ecological civilization, the construction of forest cities has become an important measure to promote urban ecosystem restoration and achieve sustainable development. Based on the mechanism of forest city promoting green development, the construction of a national forest city is regarded as a “quasi-natural experiment”. Using China’s urban panel data from 2005 to 2019, the impact of national forest city construction on urban green total factor productivity was evaluated using Multistage asymptotic double difference. The results show that National Forest Cities with environmental regulation can significantly promote regional green total factor productivity, which is still valid after a series of Robustness tests. Mechanism analysis shows that forest city construction not only affects territorial spatial planning but also forms a linkage with green technology innovation, mutual promotion and mutual promotion to jointly promote the sustainable development goals. This paper argues that building a national forest city is an important measure to achieve China’s sustainable development goals in the new era, but in the process of policy implementation, it is necessary to implement the national forest city selection system according to local conditions.