The head of Libya's unity government, Fayez al-Sarraj, who plans to resign as part of peace efforts, has held his post through five years of economic crisis and deadly infighting that has drawn in foreign powers.
A political novice when his Government of National Accord was established with UN support in 2015, Sarraj successfully faced down his rival Khalifa Haftar, an eastern-based military leader accused of seeking to re-establish a dictatorship.
In April 2019, Haftar launched a devastating offensive against Tripoli, seat of Sarraj's government, saying he wanted to cleanse it of "terrorists and mercenaries".
But in June this year, Sarraj's troops forced Haftar's fighters to fall back on the east, after driving them out of their last western toeholds.
The two sides have since met for peace talks in Morocco, after last month announcing a surprise ceasefire and pledging to hold national elections.
Sarraj said during a brief televised address late Wednesday that he was willing to leave his post in favour of a new executive determined by the talks.
"I announce to all my sincere wish to cede my functions to the next administration before the end of October at the latest," he said.
Sarraj, tall and often elegantly dressed, with a grey beard, was born in 1960 into a powerful, conservative family with large business interests and swathes of real estate.
His father, Mustafa, played a key role in founding the state after independence in 1951.
An architect by trade, Sarraj was elected to Libya's parliament in June 2014.
Just two months later, an alliance of militias called Libya Dawn seized control of the capital. The government and members of the new parliament were forced to seek refuge in the country's east.
Sarraj moved to Tobruk, where the parliament is still based, and sent his wife, also an architect, and three daughters to safety abroad.
Described by a childhood friend as "very calm", in 2015 he was appointed head of the GNA, established under a UN-brokered deal signed in the Moroccan city of Skhirat.
After being stranded for months in Tunis, as Libya Dawn forces controlled Tripoli, in March 2016, Sarraj finally boarded a Libyan navy vessel to Tripoli, where he won the recognition of key political and economic authorities.
But throughout his term, Sarraj was unable to win the confidence of the country's parliament. Elected in 2014 and based in the country's east, the legislature had backed Haftar until his attack on the capital in 2019 prompted dozens of MPs to move to Tripoli and establish another parliament there.
Successes and failures
Sarraj's arrival in Tripoli, nominally held by the GNA but in reality controlled by an array of armed groups, had raised hopes for a solution to the violence that has ravaged Libya since the overthrow of longtime dictator Moamer Kadhafi in 2011.
He made concerted efforts to put the institutions of the Libyan state in order and start a process of national reconciliation, but he was thwarted -- not least by Haftar's offensive against the capital.
Haftar, who has long presented himself as bulwark against jihadists, had won the backing of Egypt, the United Arab Emirates and Russia.
The GNA has been backed by Turkey, whose military aid -- notably drones -- was crucial in pushing back Haftar's forces and reasserting the unity government's clout across western Libya in June.
That turnaround was a second key victory for the GNA, which in December 2016 had retaken the city of Sirte -- Kadhafi's birthplace -- from Islamic State group jihadists.
But those military successes have been accompanied by a string of failures.
Unable to establish functioning police or military forces, the GNA has been forced to rely on a handful of powerful armed groups that eventually found their way into the corridors of power in state institutions.
It has struggled to provide Tripolitans with services, security or jobs or to tackle a biting economic crisis -- despite Libya sitting on Africa's largest oil reserves.
Hundreds of fed-up Libyans protested in Tripoli in August to denounce not just electricity and water shortages, but also official corruption.