The UN demanded an independent inquiry on Wednesday after a military strike on a Libyan detention centre for migrants killed 44 people, including women and children, and wounded 130.
UN Secretary General Antonio Guterres described the attack east of Tripoli as horrendous, as rival sides in the country's conflict appeared to blame each other for the incident.
The Tajoura detention centre was hit late on Tuesday, but it was not immediately clear if the cause was an air strike or an artillery shell. Mr Guterres said the exact coordinates of the centre had been provided to the warring parties to ensure that it was spared from becoming a military target.
Ghassan Salame, the secretary-general's special envoy to Libya, said the attack could constitute a war crime and he urged the international community to punish those who ordered, carried out and provided arms for the strike. It was the second time the facility had been attacked.
"The absurdity of this ongoing war today has led this odious bloody carnage to its most hideous and most tragic consequences," Mr Salame said.
The incident was by far the biggest single-day casualty toll since fighting broke out in Tripoli three months ago when Field Marshal Khalifa Haftar launched an offensive on the capital days before UN-sponsored talks about national reconciliation were due to start.
Gen Haftar, commander of the self-styled Libyan National Army, has been fighting militias loyal to the UN-recognised Government of National Accord.
"There were bodies, blood and pieces of flesh everywhere," a survivor, 26-year-old Al-Mahdi Hafyan from Morocco, told the AFP news agency from his hospital bed where he was being treated for a leg wound.
The Tripoli-based government blamed the LNA for the air strike and called for the UN support mission in Libya to establish a fact-finding committee to investigate.
An LNA official denied that the force had hit the detention centre, saying in a statement that militias allied to Tripoli had shelled it after a precision air strike by the LNA on a military camp. Local media reported that the LNA's action had included air strikes against a militia camp near the detention centre.
The Security Council has been divided on how to address the Libyan conflict, with the US resisting calls from other leading countries for a ceasefire and a return to political dialogue. "The Americans have been reluctant to act, up until this point at least," a senior diplomat told The National.
But even before Tuesday's deaths moves were afoot on the council to push again for a ceasefire amid mounting worries that an influx of weapons to both sides – in contravention of a UN arms embargo – could fuel the conflict, which has hit a stalemate.
Around 600 migrants and refugees were held in the Tajoura centre, the head of the compound Noureddine al-Grifi said, adding that other people were wounded in another hangar.
UNHCR spokesman Charlie Yaxley said in Geneva that the refugee agency had asked to have the centre evacuated a few weeks ago after "a near miss from a similar air strike".
Field Marshal Haftar's forces control much of the country's east and south but were dealt a significant blow last week when militias allied with the Tripoli government reclaimed the strategic town of Gharyan, about 100 kilometres from the capital. Gharyan had been a key supply route for the LNA forces.
Many camps for militias loosely allied with the UN-supported government are in Tajoura, and LNA forces have attacked such camps with air strikes in the past weeks. The LNA said on Monday it had begun an air campaign on rival fighters in Tripoli after it lost control of Gharyan.
The fighting for Tripoli has threatened to plunge Libya into another bout of violence on the scale of the 2011 conflict that ousted longtime dictator Muammar Qaddafi and led to his death.
