Wealthy nations endorsed South Africa's plan to transition away from coal on Monday, paving the way for an $8.5 billion deal that could serve as a template for other developing countries.

The announcement was made at the UN's COP27 climate summit in Egypt's Sharm el-Sheikh, where developed countries are under pressure to step up their efforts to aid developing countries green their economies.

Britain, France, Germany, the United States and the European Union will provide the funds in the form of grants and loans to help South Africa decarbonise its economy, they said in a joint statement.

The Just Energy Transition Partnership (JETP) was first announced last year at the COP26 in Glasgow.

Negotiations were tricky, with South African President Cyril Ramaphosa saying Friday that the country needed more money to green its economy.

Africa's biggest economy relies on coal for 80 percent of its electricity generation.

The nations providing the $8.5 billion, known collectively as the International Partners Group, said the funding will go towards decommissioning coal power plants and investments to accelerate the deployment of renewable energy.

"Our support for South Africa's clean energy and infrastructure priorities, which include efforts to provide coalminers and affected communities the assistance that they need in this transition, will help South Africa's clean energy economy thrive," US President Joe Biden said in the joint statement.

© Agence France-Presse