Green finance policy has emerged as a powerful driver for sustainable development worldwide, which has arisen at the top of the political agenda. Drawing on resource allocation theory, this study empirically investigates whether and how green finance policy affects corporate environmental responsibility in achieving sustainable development goals on a micro level. Taking China’s green finance reform and innovation (GFRI) pilot policy as a quasi-natural experiment, this paper employs the difference-in-differences model to investigate the impact of green finance policy on corporate environmental responsibility. The evidence shows that the GFRI policy significantly promotes corporate environmental responsibility. The results hold robust after a series of checks such as parallel trend examination, placebo test, exclusion of other policies, and alternative variable measurement. Moreover, this study explores the potential mechanism channels from the perspective of resource allocation theory. Specifically, green finance policy ultimately accelerates corporate environmental responsibility through financing capacity and environmental protection supervision. The heterogeneity analysis shows that the positive impact of the GFRI policy on corporate environmental responsibility is more pronounced for companies in areas with superior green development, strong law enforcement, and higher levels of pollution. The above findings indicate that the formal institution of government-led green financial policy can positively affect corporate environmental responsibility, with regional green development and law enforcement factors enhancing the effectiveness of these policies. Furthermore, the level of local pollution further intensifies the corporate sensibility to such policy effects. Overall, our study sheds light on the significant role of green financial policy in fostering a sustainable economy, helping reconcile the mixed evidence on the financial function of green finance policy on the firm level.