Libyan military strongman Khalifa Haftar agreed "in principle" Thursday to attend a peace conference in Berlin after the head of Tripoli's UN-recognised government Fayez al-Sarraj signalled he would be present.
The talks come as world powers step up efforts for a lasting ceasefire, nine months since an assault on Tripoli by Haftar's forces sparked fighting that has killed more than 280 civilians and 2,000 fighters, displacing thousands.
An interim ceasefire which came into force last Sunday has mostly held, despite accusations of violations from Haftar's forces and the rival Tripoli-based Government of National Accord (GNA).
GNA chief Sarraj told military chiefs in Tripoli on Thursday that "we are going to be present in Berlin" for the talks on Sunday.
Haftar had walked away from ceasefire talks in Moscow on Monday, but Germany Foreign Minister Heiko Maas visited his eastern Libya stronghold of Benghazi on Thursday to persuade him to join the conference.
Haftar "wants to contribute to the success of the Libyan conference in Berlin and is in principle ready to participate in it," Maas tweeted, calling the talks "the best chance in a long time" for peace.
Haftar "has agreed to abide by the ongoing ceasefire", he added.
But Sarraj, whose GNA did sign the Moscow deal, cast doubt over Haftar's intentions.
Haftar "has chosen not to sign the agreement and asked for a delay", he said, calling that "an attempt to undermine the Berlin conference before it starts".
The oil-rich North African state has been in turmoil since dictator Moamer Kadhafi died in the 2011 NATO-backed uprising and multiple foreign powers have become embroiled.
The GNA is backed by Turkey and Qatar, while Haftar, who backs a rival administration in Libya's east, has the support of neighbouring Egypt, Russia and the United Arab Emirates.
The United Nations said the Berlin talks aim to end foreign interference and division over Libya.
UN Secretary-General Antonio Guterres called Wednesday for firm support for the peace talks and asked for a halt in the fighting.
In a report to the Security Council he urged all parties to "engage constructively towards that end, including within the Berlin process".
Guterres also warned against "external interference", saying it would "deepen the ongoing conflict and further complicate efforts to reach a clear international commitment to a peaceful resolution of the underlying crisis".
The conference will aim to agree six points including a permanent ceasefire, implementation of a much-violated UN arms embargo and a return to political efforts for peace, Guterres said.
Turkey has deployed military forces to support the GNA, while despite its denials, Russia is suspected of supporting Haftar with weapons, money and mercenaries.
Neighbouring Tunisia, which shares a 450-kilometre (280-mile) border with Libya and fears an escalation could spark an influx of thousands of refugees, voiced disappointment Thursday at not being invited to the conference.
Some 11 countries and several international organisations are set to attend along with the Libyan parties.
Tunisia's ambassador to Germany voiced consternation in an interview with Deutsche Welle and this was confirmed by the foreign ministry in Tunis, which would not comment further.
Italian Prime Minister Giuseppe Conte joined the swell of international pressure for a ceasefire during talks in Algiers in Thursday, officials said.
He met the Algerian prime minister and the president as part of "efforts to circumscribe the conflict in Libya and bring a durable solution", an Algerian foreign ministry statement said.
The fighting has spurred a growing exodus of migrants, many embarking on rickety boats towards Italy.
Nearly 1,000 intercepted at sea have been forced to return to the war-ravaged country since January 1, mostly ending up in detention, the UN's International Organization for Migration said Tuesday.