SAO PAULO, June 10 (Reuters) - Brazil's Eletrobras , Latin America's largest utility, has signed a deal to sell its portfolio of thermoelectric power plants to Ambar Energia for a total 4.7 billion reais ($878.01 million), it said in a securities filing on Monday.

The deal's price tag includes an earn-out of 1.2 billion reais, according to Eletrobras. Under the agreement, Ambar would take on the credit risk of the energy contracts the plants are subject to.

The transaction resulted from a competitive process launched in July 2023 by Eletrobras, which had been privatized a year earlier, as part of its goal of reaching net-zero carbon emissions by 2030.

The company said the "high engagement" process allowed it to maximize the value of its assets with "adequate" risk allocation.

The 12 gas-fired plants sold by Eletrobras, including the firm's last operating thermoelectric assets, have a total installed capacity of 2 gigawatts (GW). The deal also includes the project for a plant in Manaus, a town in northern Brazil.

Eletrobras' thermoelectric portfolio will be transferred without any debt or cash to Ambar, a local energy firm owned by conglomerate J&F - which also controls the world's largest meatpacker, JBS.

($1 = 5.3530 reais) (Reporting by Luana Maria Benedito and Leticia Fucuchima; Editing by Gabriel Araujo)