(Bloomberg) -- Cyril Ramaphosa was reelected as South Africa’s president, hours after his African National Congress agreed a power-sharing deal with business-friendly opposition parties.

Ramaphosa won 283 of the votes cast by members of National Assembly on Friday night, and Economic Freedom Fighters leader Julius Malema 44. Parties including the Democratic Alliance and Inkatha Freedom Party supported the incumbent’s candidacy for another five-year term, and in exchange will be allocated cabinet posts and key positions in the legislature.

“This is a historic juncture in the life of our country, which requires that we must work and act together to entrench our constitutional democracy and the rule of law, and build a South Africa for all of its people,” Ramaphosa said after his election in Cape Town. “It is with this in mind that I declare that I accept the mission you are giving me.”

The FTSE/JSE Africa All Share Index rose 0.9% on Friday following the formation of the broad alliance, while the rand gained as much as 0.7% to 18.305 per dollar. 

South Africa has been in political flux since May 29 elections, when the ANC lost its parliamentary majority for the first time since it took power three decades ago, garnering slightly more than 40% of the vote. While the ANC proposed the country be ruled by a broad alliance known as a government of national unity, former President Jacob Zuma’s new uMkhonto weSizwe Party and the leftist EFF refused to join, leaving the DA, IFP and other smaller parties as its members. 

The 400-member assembly earlier elected the ANC’s Thoko Didiza, a former agriculture minister, as speaker and the DA’s Annelie Lotriet as her deputy. Ramaphosa is due to be inaugurated on June 19 and announce his cabinet soon thereafter.

The participants are united in their shared respect for the constitution, and will work together to grow the economy, create jobs and tackle crime, DA leader John Steenhuisen said in a speech on the party’s YouTube channel. Positions in the cabinet and legislatures will be allocated broadly in proportion to the parties’ share of seats, although appointments have yet to be discussed, he told reporters. 

The makeup of the ruling coalition has buoyed financial markets because the new administration is likely to back Ramaphosa’s efforts to rein in state debt and tackle power shortages and logistics snarl-ups that have hobbled Africa’s biggest economy. The exclusion of parties that support land expropriation and the nationalization of mines and banks will also help shore up investor sentiment. 

A framework for the new government is still being worked out, and it’s unclear which small parties will join, with the situation still “very fluid,” ANC Secretary-General Fikile Mbalula said in an interview.

“The next phase will be to form a national dialog with all parties in the government of national unity in which policy will be hammered out,” said Corne Mulder, chief whip of the Freedom Front Plus, the seventh-largest party. These discussions won’t include any changes to the constitution.

“We may have an interim cabinet until that national dialog is concluded,” Mulder said. “Although Ramaphosa wants to reduce the size of the cabinet, he may be forced to keep it at the current numbers in order to accommodate everybody.”

The durability of the governing coalition will be put to the test over coming months, given the historically fractious relations between its members. 

The ANC has previously sought to portray the DA as representing the interests of big business and South Africa’s White minority, and has in turn been accused of governing ineptly and failing to tackle endemic corruption. And the ANC and IFP fought an undeclared civil war in the 1980s and 1990s that was fueled by the apartheid regime and claimed thousands of lives before a truce was declared. 

Power-sharing at municipal level has also been problematic. Control of several of South Africa’s main cities that are ruled by multiple parties has repeatedly changed hands as allegiances have shifted, and the instability has caused the delivery of water, refuse removal and other services to grind to a near-halt. 

Sign up here for the twice-weekly Next Africa newsletter

One of South Africa’s most experienced politicians, the 71-year-old Ramaphosa will play a central role in trying to ensure the new administration runs smoothly and endures. He trained as a lawyer, co-founded the National Union of Mineworkers and established a reputation as deft negotiator when he led the historic talks that ended apartheid and produced the nation’s first democratic constitution. 

He was appointed president in February 2018 and faced the formidable tasks of fixing an economy hamstrung by years of mismanagement, policy uncertainty and an energy crisis, addressing a chronic lack of jobs and tackling the graft that became institutionalized during his predecessor’s tenure. 

He made some headway, firing a number of officials implicated in corruption and instituting several reforms, but power shortages, inept state institutions and the coronavirus pandemic have hindered efforts to engineer a turnaround.

You can follow Bloomberg’s reporting on Africa on WhatsApp. Sign up here.

--With assistance from Arijit Ghosh and Monique Vanek.

(Updates with Ramaphosa’s comments in third paragraph. An earlier version of this story corrected the vote count for Malema in second paragraph.)

©2024 Bloomberg L.P.