|African migrants to Europe|
Having paid human traffickers in the hope of finding a better life many instead were held hostage and their families extorted for ransom.
The International Organization for Migration said "slave market conditions" and detention were increasingly common as criminal gangs sought to cash in.
"Selling human beings is becoming a trend among smugglers as the smuggling networks in Libya are becoming stronger," Othman Belbeisi, the IOM's chief of mission in Libya, told reporters in Geneva.
"Migrants ... are being sold in markets as a commodity" at a going rate of between $200 and $500 a head, he said.
While some migrants sold this way managed to escape, many wallowed in captivity for months before being bought free or sold on.
The UN agency could not provide statistics over how many people were affected, but relied on accounts provided to its staff on the ground.
In one case, a Senegalese migrant identified only as S.C., told IOM staff he had been held captive for months after he made the perilous journey to Libya.
After paying a trafficker more than $300 to arrange for him to be driven through the desert, he was apparently conned when he arrived in Libya, with a truck driver saying the trafficker never paid him the money.
The driver had taken S.C. and other migrants to a parking area where a "slave market" was taking place, an IOM statement said.
"Sub-Saharan migrants were being sold and bought by Libyans," the statement said, citing staff in Niger who took the man's testimony.
S.C. described being bought and taken to a private home where more than 100 migrants were held as hostages.
They were forced to call their families back home, and were beaten while on the phone, to try and make sure they would get the money demanded for their freedom.
"When somebody died or was released, kidnappers returned to the market to 'buy' more migrants to replace them," the statement said.
"Women too were bought by private individuals ...(and) were forced to be sex slaves," it added.
An IOM staff member in Niger had spoken with a number of migrants in recent days who "all confirmed the risks of being sold as slaves in squares or garages" once in Libya, it said.
Some migrants, mainly Nigerians, Ghanaians and Gambians, were also "forced to work for the kidnappers/slave traders as guards in the ransom houses or in the 'market' itself," the IOM staff member said.
One migrant, whose name was not given, told IOM he and 25 other Gambians were taken to a "prison" in Libya, and was beaten every day for nine months before his father paid for his release by selling the family home.
When he was freed he weighed just 35 kilos and was suffering from severe malnutrition and numerous torture wounds.