The UN refugee agency said on Friday it was gravely concerned about a deterioration in conditions for migrants held in Libyan detention centres that had led to riots and hunger strikes.
Many migrants are taken to the centres after being intercepted by Libya's EU-backed coastguard as they try to reach Europe by sea, a policy that has been criticised by human rights groups.
An estimated 8,000 migrants are currently held in 18 detention centres linked to the internationally recognised government in Tripoli, according to UNHCR.
Those detained make up a small fraction of the several hundred thousand migrants resident in Libya or passing through the North African country.
Humanitarian workers have limited access to the centres, which frequently open and close.
"In recent weeks, UNHCR has witnessed a critical worsening in conditions in detention centres, due to the increasing overcrowding and lack of basic living standards," the agency said in a statement.
"As a consequence, riots and hunger strikes by refugees inside detention centres are taking place, demanding a resolution to their bleak living conditions.
"This has led to a number of serious security incidents, where UNHCR frontline staff have been placed at physical risk."
Libyan officials have blamed poor conditions at detention centres on a lack of resources, and have said migrants are detained for their own protection.
Departures of mainly sub-Saharan African migrants from Libya to Italy peaked between 2014-2017 as the country slid further into turmoil following a NATO-backed uprising seven years ago.
Last summer smuggler networks were disrupted under heavy pressure from Italy, and Libya's coastguard stepped up interceptions.
So far this year 12,174 migrants have landed in Italy from Libya, nearly 87 per cent fewer than during the same period in 2017, according to Italian interior ministry statistics.
There are nearly 55,000 refugees and asylum seekers registered in Libya, where they face limited chances of resettlement, according to UNHCR.