Libyan forces under Khalifa Haftar battled their way to the south of Tripoli on Friday, prompting the UN Security Council and the G7 to demand a halt to the military advance on the capital.
Haftar, commander of the self-proclaimed Libyan National Army (LNA), launched an offensive on Thursday to take the capital, held by a UN-backed unity government and an array of militias.
The lightening assault was ordered as UN Secretary-General Antonio Guterres was in Libya for a visit aimed at cementing a political deal on holding elections.
After meeting with Haftar in the eastern city of Benghazi, Guterres said he was leaving "Libya with a deep concern and a heavy heart" and voiced hope that a "bloody confrontation" could be avoided.
Shortly afterwards, LNA forces clashed with a pro-government alliance less than 50 kilometres (30 miles) south of the capital, a unity government source said.
After a closed-door emergency meeting in New York, the Security Council called on Haftar's forces to halt their advance and warned that those responsible for re-igniting the conflict will be held responsible.
The appeal for Haftar to halt his offensive was unanimously backed by the council, including Russia, which has supported the strongman.
The council "called on LNA forces to halt all military movements" and "on all forces to de-escalate military activity," said German Ambassador Christoph Heusgen, who holds the council presidency.
UN envoy Ghassan Salame told the council that Haftar made clear to Guterres during the Benghazi meeting that he had no intention of halting his campaign, diplomats said.
G7 foreign ministers meeting in the French resort town of Dinard urged an immediate halt to "all military activity and movements toward Tripoli", warning that civilians were in danger.
The United States and its allies issued a joint statement urging "all parties to immediately de-escalate tensions".
Russia called for "all possible efforts to fully resolve the situation with peaceful political means".