Countries and companies across the globe are finally getting serious about climate change.

For Latin America, this quickening green transition could attract hundreds of billions in investment, help spur an economic recovery and let nations leapfrog technologically. What’s needed is a policy U-turn, particularly in Brazil and Mexico, its two biggest economies. If their leaders don’t get out of their own way, the region will be left behind.

Dozens of nations have shored up commitments to slow rising temperatures in the run-up to November’s next United Nations climate change conference, COP26, in Glasgow. Europe and the U.S. have pledged to halve or more their emissions over the next decade. Emerging economies have promised to trim future emissions and step up adaptation by redesigning cities and rethinking agricultural practices.