Digital transformation has already begun to play a significant role in helping EU countries to achieve sustainable values by promoting environmental, social and governance (ESG) efficiency. It is rapidly changing the economic landscape, which leads to changes in all sectors and at all levels. The European Union (EU) has set ambitious goals for sustainable development and climate change mitigation, such as the European Green Deal and the 2030 Agenda for Sustainable Development. The paper aims to test the spatial spillover effect of digitalization on ESG performance for EU countries for 2008–2020. The study applies the spatial Durbin model to check the research hypothesis. The empirical results revealed that the EU exhibits varying levels of ESG performance. Digital transformation has the potential to enhance ESG performance and has shown significant spatial spillover effects. The SDM estimates that a 1% increase in digital inclusion results in a minimal 0.001% increase in the ESG index. The statistically significant positive effects observed in key enablers, digital public services for businesses and citizens, highlight the contribution of digitalization to improving ESG performance. In addition, technological innovation serves as a critical conduit for transmitting digital transformation in the business and public sphere to ESG performance. Given these findings, policymakers are advised to strengthen digitalization efforts to narrow the digital divide, leveraging the digital economy as a potent instrument. Additionally, a dynamic and targeted strategy for digital economic development should be implemented to address ESG performance disparities effectively.