Eastern-based commander Khalifa Haftar, Tripoli Prime Minister Fayez Seraj, and the leaders of rival parliamentary assemblies, all attended talks in Paris.
Rival Libyan factions agreed on Tuesday to hold parliamentary and presidential elections on December 10, an adviser to Libyan Prime Minister Fayez Seraj said following a meeting in Paris.
Taher al Sonni said in a tweet that four parties gathered at the talks had also agreed on "finalising a constitutional base for elections" by September 16.
Libya splintered following the 2011 NATO-backed revolt that toppled Muammar Gaddafi, and since 2014 has been divided into competing political and military factions based in Tripoli and the east. The United Nations is leading an effort to reunify the oil-rich nation and to organise national elections.
The Paris meeting, which included eastern-based commander Khalifa Haftar, Tripoli Prime Minister Fayez Seraj, and the leaders of rival parliamentary assemblies, aims to urge them to agree to general principles for ending Libya's crisis and moving towards elections.
"Positive that all Libya parties present at Paris conference agreed timeline leading to elections in December," Malta's Prime Minister Joseph Muscat said from inside the meeting. "Let us hope, and help them in keeping this important commitment."
A draft document seen by Reuters ahead of the meeting includes the call for the immediate unification of the central bank and a commitment to support the creation of a national army. It also agrees to an inclusive political national conference and threatened international sanctions on those that impede the accord or dispute the outcome of elections.
Several countries, including the five permanent members of the UN Security Council, Italy, Turkey, United Arab Emirates, Qatar and Libya's neighbours were attending the meeting.
Elena Casas has more from Paris.
Past attempts at peace deals in Libya have often been scuttled by internal divisions among the country's competing armed groups and by the different countries backing the local actors.
Under Macron, France has tried to play a bigger role in coaxing Libya's factions to end the turmoil, which has let militants gain a foothold and allowed migrant smugglers to flourish.