Former Senegalese minister and UN diplomat Abdoulaye Bathily will be the new UN envoy to Libya after the Security Council approved the appointment.
This ends a nine-month search to fill the post, amid increasing chaos in the oil-rich north African nation.
The last UN special representative, Jan Kubis, resigned in November last year after 10 months on the job, and a number of replacements proposed by Secretary General Antonio Guterres were rejected by council members, Libya or neighbouring countries.
In December, Mr Guterres appointed veteran American diplomat Stephanie Williams, a former UN deputy special representative in Libya, as his special adviser — a job that did not require council approval.
She resigned at the end of July, leaving the UN mission in Libya without a leader amid a constitutional and political crisis.
Mr Guterres said Mr Bathily brings 40 years of experience to his new role in Libya.
Mr Bathily held various ministerial positions in Senegal, taught history for more than 30 years at the Universite Cheikh Anta Diop in Dakar, held senior UN positions including in Mali and Central Africa, and served as the independent expert for the strategic review of the Libya mission in 2021.
He has doctorates from Universite Cheikh Anta Diop and the University of Birmingham in the United Kingdom and is fluent in English, French, Soninke and Wolof.
Libya’s transitional government, which opposed Mr Bathily’s nomination, reportedly sent a protest letter to Mr Guterres, which raises questions about how effective the new envoy can be in trying to resolve the country’s crisis.
The United States welcomed the appointment, saying heavy fighting that broke out between militias in Tripoli last month "underscored the unsustainability of the situation in Libya, making clear the need for all sides to work in good faith and with a sense of urgency to reach agreement on a constitutional framework and concrete timeline for elections".
"The United States will provide full support to Special Representative Bathily as he mediates the Libya-led political process, and we call upon the international community to work in lockstep with the special representative," Secretary of State Antony Blinken said.
Libya has been in chaos since a popular uprising toppled and killed longtime dictator Muammar Qaddafi in 2011. The county has for years been split between rival administrations, each backed by militias and foreign governments.
UN political chief Rosemary DiCarlo gave a warning on Tuesday that failure to resolve Libya’s political crisis and hold delayed elections posed a growing threat to the country.
She highlighted recent clashes that killed at least 42 people and injured 159 others, according to a tally released by Libyan authorities.
The continuing stalemate grew out of the failure to hold elections in December and the refusal by Prime Minister Abdul Hamid Dbeibah, who led the transitional government, to step down. In response, the country’s east-based parliament appointed a rival prime minister, Fathi Bashagha, who has for months sought to install his government in Tripoli.
Underlining the challenge facing Mr Bathily, clashes broke out in the western outskirts of Tripoli late on Friday and early Saturday as forces aligned with Mr Dbeibah's government consolidated their control over the capital.
The fighting in Warshafala district, along with a major pro-Dbeibah group taking over a military headquarters in southern Tripoli, come a week after groups allied to the rival prime ministers engaged in Libya's heaviest fighting in two years.
The clashes in and around the capital fighting dislodged several groups that had aligned with Mr Bashagha, who served as interior minister in the former Tripoli government.
Following last week's fighting, both Mr Bashagha and Mr Dbeibah made visits to Turkey, which helped the now-divided western factions fight off an eastern assault in 2020.
Turkey retains a military presence around Tripoli, including drones that could play a critical role in deciding the outcome of any major bout of warfare if it decided to back a side.
In the fighting late on Friday and early on Saturday, a witness told Reuters that mortars were fired in Warshafana, a district of farmland, villages and patches of urban sprawl between Tripoli and the western city of Zawiya.
During last week's fighting, a major Bashagha-aligned faction based in Zawiya was said to be among groups that were repulsed from the outskirts of the capital.
In the southern Tripoli district of Ain Zara, a powerful faction that backed Mr Dbeibah during last week's fighting took over a security headquarters. Fighters and vehicles bearing its insignia stood guard there on Saturday morning with checkpoints set up nearby.
With reporting from AP and Reuters.