When the European Union started funnelling millions of euros into Libya to slow the tide of migrants crossing the Mediterranean, the money came with EU promises to improve detention centres notorious for abuse and fight human trafficking.

That has not happened. Instead, the misery of migrants in Libya has spawned a thriving and highly lucrative web of businesses funded in part by the EU and enabled by the United Nations, an Associated Press investigation has found.

More:

The EU has sent more than 327.9 million euros to Libya, with an additional 41 million approved in early December, largely funnelled through UN agencies. The AP found that in a country without a functioning government, huge sums of European money have been diverted to intertwined networks of militiamen, traffickers and coast guard members who exploit migrants.

In some cases, UN officials knew militia networks were getting the money, according to internal emails.

The militias torture, extort and otherwise abuse migrants for ransoms in detention centres under the nose of the UN, often in compounds that receive millions in European money, the investigation showed.

Many migrants also simply disappear from detention centers, sold to traffickers or to other centres.

The same militias conspire with some members of Libyan coast guard units. The coast guard gets training and equipment from Europe to keep migrants away from its shores. But coast guard members return some migrants to the detention centres under deals with militias, the AP found, and receive bribes to let others pass en route to Europe.

The militias involved in abuse and trafficking also skim off European funds given through the UN to feed and otherwise help migrants, who go hungry. For example, millions of euros in UN food contracts were under negotiation with a company controlled by a militia leader, even as other UN teams raised alarms about starvation in his detention centre, according to emails obtained by the AP and interviews with at least a half-dozen Libyan officials.

In many cases, the money goes to neighbouring Tunisia to be laundered, and then flows back to the militias in Libya.

Highly complex issue

The story of Prudence Aimee and her family shows how migrants are exploited at every stage of their journey through Libya.

Aimee left Cameroon in 2015, and when her family heard nothing from her for a year, they thought she was dead. But she was in detention and incommunicado. In nine months at the Abu Salim detention centre, she told the AP she saw "European Union milk" and nappies delivered by UN staff pilfered before they could reach migrant children, including her toddler son. Aimee herself would spend two days at a time without food or drink, she said.

In 2017, an Arab man came looking for her with a photo of her on his phone.

"They called my family and told them they had found me," she said. "That's when my family sent money." Weeping, Aimee said her family paid a ransom equivalent of $670 to get her out of the centre. She could not say who got the money.

She was moved to an informal warehouse and eventually sold to yet another detention centre, where yet another ransom - $750 this time - had to be raised from her family. Her captors finally released the young mother, who got on a boat that made it past the coast guard patrol, after her husband paid $850 for the passage.

A European humanitarian ship rescued Aimee, but her husband remains in Libya.

Aimee was one of more than 50 migrants interviewed by the AP at sea, in Europe, Tunisia and Rwanda, and in furtive messages from inside detention centres in Libya. Journalists also spoke with Libyan government officials, aid workers and businessmen in Tripoli, obtained internal UN emails and analysed budget documents and contracts.

The issue of migration has convulsed Europe since the influx in 2015 and 2016 of more than a million people fleeing violence and poverty in the Middle East, Afghanistan and Africa. In 2015, the European Union set up a fund intended to curb migration from Africa, from which money is sent to Libya. The EU gives the money mainly through the UN's International Organization for Migration (IOM) and the High Commissioner for Refugees (UNHCR).

Rescued migrants look at a map of Europe aboard the Ocean Viking humanitarian ship [Renata Brito/AP]

But Libya is plagued by corruption and caught in a civil war. The country's west, including the capital Tripoli, is ruled by a UN-brokered government, while the east is ruled by another government supported by army commander Khalifa Haftar. The chaos is ideal for profiteers making money off migrants.

The EU's own documents show it was aware of the dangers of effectively outsourcing its migration crisis to Libya. Budget documents from as early as 2017 for a 90-million-euro outlay warned of a medium to high risk that Europe's support would lead to more human rights violations against migrants, and that the Libyan government would deny access to detention centres.

A recent EU assessment found the world was likely to get the "wrong perception" that European money could be seen as supporting abuse.

If you were to treat dogs in Europe the way these people are treated, it would be considered a societal problem. Julien Raickman, former head of Libya mission with MSF

Despite the roles they play in the detention system in Libya, both the EU and the UN say they want the centres closed. In a statement to the AP, the EU said that under international law, it is not responsible for what goes on inside the centres.

"Libyan authorities have to provide the detained refugees and migrants with adequate and quality food while ensuring that conditions in detention centres uphold international agreed standards," the statement said.

The EU also says more than half of the money in its fund for Africa is used to help and protect migrants, and that it relies on the UN to spend the money wisely.

The UN said the situation in Libya was highly complex, and it has to work with whoever runs the detention centres to preserve access to vulnerable migrants.

"UNHCR does not choose its counterparts," said Charlie Yaxley, a spokesman for the UN refugee agency. "Some presumably also have allegiances with local militias."

After two weeks of being questioned by the AP, UNHCR said it would change its policy on awarding food and aid contracts for migrants through intermediaries.

"Due in part to the escalating conflict in Tripoli and the possible risk to the integrity of UNHCR's programme, UNHCR decided to contract directly for these services from 1 January 2020," Yaxley said.

Julien Raickman, who until recently was the Libya mission chief for the aid group Doctors Without Borders, known by its French initials MSF, believes the problem starts with Europe's unwillingness to deal with the politics of migration.

"If you were to treat dogs in Europe the way these people are treated, it would be considered a societal problem," he said.

Extortion inside the detention centres

About 5,000 migrants in Libya are crowded into between 16 and 23 detention centres at any given time, depending on who is counting and when. Most are concentrated in the west, where the militias are more powerful than the weak UN-backed government.

Aid intended for migrants helps support the al-Nasr Martyrs detention centre, named for the militia that controls it, in the western coastal town of Zawiya. The UN's migration agency, the IOM, keeps a temporary office there for medical checks of migrants, and its staff and that of the UNHCR visit the compound regularly.

Yet migrants at the centre are tortured for ransoms to be freed and trafficked for more money, only to be intercepted at sea by the coast guard and brought back to the centre, according to more than a dozen migrants, Libyan aid workers, Libyan officials and European human rights groups.

A UNHCR report in late 2018 noted the allegations as well, and the head of the militia, Mohammed Kachlaf, is under UN sanctions for human trafficking. Kachlaf, other militia leaders named by the AP and the Libyan coast guard all did not respond to requests for comment.

Many migrants recalled being cut, shot and whipped with electrified hoses and wooden boards. They also heard the screams of others emerging from the cell blocks off-limits to UN aid workers.

Families back home are made to listen during the torture to get them to pay, or are sent videos afterwards.

Eric Boakye, a Ghanaian, was locked in the al-Nasr Martyrs centre twice, both times after he was intercepted at sea, most recently around three years ago.

The first time, his jailers simply took the money on him and set him free. He tried again to cross and was again picked up by the coast guard and returned to his jailers.

"They cut me with a knife on my back and beat me with sticks," he said, lifting his shirt to show the scars lining his back. "Each and every day they beat us to call our family and send money." The new price for freedom: Around $2,000.

Eric Boakye and other rescued migrants pray for Europe to grant them a place of safety [Renata Brito/AP]

That was more than his family could scrape together. Boakye finally managed to escape. He worked small jobs for some time to save money, then tried to cross again. On his fourth try, he was picked up by the Ocean Viking humanitarian ship to be taken to Italy. In all, Boakye had paid $4,300 to get out of Libya.

Fathi al-Far, the head of the al-Nasr International Relief and Development agency, which operates at the centre and has ties to the militia, denied that migrants are mistreated. He blamed "misinformation" on migrants who blew things out of proportion in an attempt to get asylum.

"I am not saying it's paradise - we have people who have never worked before with the migrants, they are not trained," he said. But he called the al-Nasr Martyrs detention centre "the most beautiful in the country."

At least five former detainees showed an AP journalist scars from their injuries at the centre, which they said were inflicted by guards or ransom seekers making demands to their families. One man had bullet wounds to both feet, and another had cuts on his back from a sharp blade.

I don't want to remember what happened. Former guard at a Libyan detention centre

All said they had to pay to get out. Five to seven people are freed every day after they pay anywhere from $1,800 to $8,500 each, the former migrants said. At al-Nasr, they said, the militia gets around $14,000 every day from ransoms; at Tarek al-Sikka, a detention centre in Tripoli, it was closer to $17,000 a day, they said.

They based their estimates on what they and others detained with them had paid, by scraping together money from family and friends.

The militias also make money from selling groups of migrants, who then often simply disappear from a centre. An analysis commissioned by the EU and released earlier this month by the Global Initiative Against Transnational Organized Crime noted that the detention centres profit by selling migrants among themselves and to traffickers, as well as into prostitution and forced labour.

Hundreds of migrants this year who were intercepted at sea and taken to detention centres had vanished by the time international aid groups visited, according to MSF. There is no way to tell where they went, but MSF suspects they were sold to another detention centre or to traffickers.

A former guard at the Khoms centre acknowledged to the AP that migrants often were seized in large numbers by men armed with anti-aircraft guns and RPGs. He said he could not keep his colleagues from abusing the migrants, or traffickers from taking them out of the centre.

"I don't want to remember what happened," he said. The IOM was present at Khoms, he noted, but the centre closed last year.

A man who remains detained at the al-Nasr Martyrs centre said Libyans frequently arrive in the middle of the night to take people. Twice this autumn, he said, they tried to load a group of mostly women into a small convoy of vehicles but failed because the centre's detainees revolted.

Fighting engulfed Zawiya last week, but migrants remained locked inside the al-Nasr Martyrs centre, which is also being used for weapons storage.

Trafficking and interception at sea

Even when migrants pay to be released from the detention centres, they are rarely free. Instead, the militias sell them to traffickers, who promise to take them across the Mediterranean to Europe for a further fee.

These traffickers work hand in hand with some coast guard members, the AP found.

The Libyan coast guard is supported by both the UN and the EU. The IOM, the UN's agency for migration, highlights its cooperation with the coast guard on its Libya home page. Europe has spent more than 90 million euros since 2017 for training and faster boats for the Libyan coast guard to stop migrants from ending up in Europe.

This fall, Italy renewed a memorandum of understanding with Libya to support the coast guard with training and vessels, and it delivered 10 new speedboats to Libya in November.

In internal documents obtained in September by the European watchdog Statewatch, the European Council described the coast guard as "operating effectively, thus confirming the process achieved over the past three years".

The Libyan coast guard says it intercepted nearly 9,000 people in 2019 en route to Europe and returned them to Libya this year, after quietly extending its coastal rescue zone 100 miles offshore with European encouragement.

What is unclear is how often militias paid the coast guard to intercept these people and bring them back to the detention centres - the business more than a dozen migrants described at the al-Nasr Martyrs facility in Zawiya.

The coast guard unit at Zawiya is commanded by Abdel-Rahman Milad, who has sanctions against him for human trafficking by the UN's Security Council. Yet when his men intercept boats carrying migrants, they contact UN staff at disembarkation points for cursory medical checks.

Despite the sanctions and an arrest warrant against him, Milad remains free because he has the support of the al-Nasr militia. In 2017, before the sanctions, Milad was even flown to Rome, along with a militia leader, Mohammed al-Khoja, as part of a Libyan delegation for a UN-sponsored migration meeting.

In response to the sanctions, Milad denied any links to human smuggling and said traffickers wear uniforms similar to those of his men.

Migrants named at least two other operations along the coast, at Zuwara and Tripoli, that they said operated along the same lines as Milad's. Neither centre responded to requests for comment.

The IOM, the UN migration agency, acknowledged to the AP that it has to work with partners who might have contacts with local militias.

"Without those contacts it would be impossible to operate in those areas and for IOM to provide support services to migrants and the local population," said Safa Msehli, the spokeswoman for the UN's International Organization for Migration.

"Failure to provide that support would have compounded the misery of hundreds of men, women and children."

The story of Abdullah, a Sudanese man who made two attempts to flee Libya, shows just how lucrative the cycle of trafficking and interception really is.

All told, the group of 47 in his first crossing from Tripoli over a year ago had paid a uniformed Libyan and his cronies $127,000 in a mix of dollars, euros and Libyan dinars for the chance to leave their detention centre and cross in two boats.

Abdullah, who tried crossing the Mediterranean from Libya, in a beach in Tunisia [Mosa'ab Elshamy/AP]

They were intercepted in a coast guard boat by the same uniformed Libyan, shaken down for their cell phones and more money, and tossed back into detention.

"We talked to him and asked him, why did you let us out and then arrest us?" said Abdullah, who asked that only his first name be used because he was afraid of retaliation. "He beat two of us who brought it up."

Abdullah later ended up in the al-Nasr Martyrs detention centre, where he learned the new price list for release and an attempted crossing based on nationality: Ethiopians, $5,000; Somalis $6,800; Moroccans and Egyptians, $8,100; and finally Bangladeshis, a minimum $18,500. Across the board, women pay more.

Abdullah scraped together another ransom payment and another crossing fee. Last July, he and 18 others paid $48,000 in total for a boat with a malfunctioning engine that sputtered to a stop within hours.

After a few days stuck at sea off the Libyan coast under a sweltering sun, they threw a dead man overboard and waited for their own lives to end. Instead, they were rescued on their ninth day at sea by Tunisian fishermen, who took them back to Tunisia.

"There are only three ways out of the prison: You escape, you pay ransom, or you die," Abdullah said, referring to the detention centre.

In all, Abdullah spent a total of $3,300 to leave Libya's detention centres and take to the sea. He ended up barely 160 km (100 miles) away.

Sometimes members of the coast guard make money by doing exactly what the EU wants them to prevent: letting migrants cross, according to Tarik Lamloum, the head of the Libyan human rights organisation, Beladi. Traffickers pay the coast guard a bribe of around $10,000 per boat that is allowed to pass, with around five to six boats launching at a time when conditions are favourable, he said.

The head of Libya's Department for Combating Irregular Migration or DCIM, the agency responsible for the detention centres under the Ministry of Interior, acknowledged corruption and collusion among the militias and the coast guard and traffickers, and even within the government itself.

"They are in bed with them, as well as people from my own agency," said Al Mabrouk Abdel-Hafez.

Skimming profits

Beyond the direct abuse of migrants, the militia network also profits by siphoning money from EU funds sent for their food and security - even those earmarked for a UN-run migrant centre, according to more than a dozen officials and aid workers in Libya and Tunisia, as well as internal UN emails and meeting minutes seen by The Associated Press.

An audit in May of the UNHCR, the UN refugee agency responsible for the centre, found a lack of oversight and accountability at nearly all levels of spending in the Libya mission. The audit identified inexplicable payments in American dollars to Libyan firms and deliveries of goods that were never verified.

In December 2018, during the period reviewed in the audit, the UN launched its migrant centre in Tripoli, known as the Gathering and Departure Facility or GDF, as an " alternative to detention". For the recipients of the services contracts, sent through the Libyan government agency Libaid, it was a windfall.

Millions of euros in contracts for food and migrant aid went to at least one company linked to al-Khoja, the militia leader flown to Rome for the UN migration meeting, according to internal UN emails seen by the AP, two senior Libyan officials and an international aid worker.

Al-Khoja is also the deputy head of the DCIM, the government agency responsible for the detention centres.

One of the Libyan officials saw the multimillion-euro catering contract with a company named Ard al-Watan, or The Land of the Nation, which al-Khoja controls.

"We feel like this is al-Khoja's fiefdom. He controls everything. He shuts the doors and he opens the doors," said the official, a former employee at the UN centre who like other Libyan officials spoke anonymously out of fear for his safety. He said al-Khoja used sections of the UN centre to train his militia fighters and built a luxury apartment inside.

Even as the contracts for the UN centre were negotiated, Libyan officials said, three Libyan government agencies, including the prosecutor's office, were investigating al-Khoja in connection with the disappearance of $570 million from government spending allocated to feed migrants in detention centres in the west.

At the time, al-Khoja already ran another centre for migrants, Tarik al-Sikka, notorious for abuses including beating, hard labour and a massive ransom scheme.

Tekila, an Eritrean refugee, said that for two years at Tarik al-Sikka, he and other migrants lived on macaroni, even after he was among 25 people who came down with tuberculosis, a disease exacerbated by malnutrition. Tekila asked that only his first name be used for his safety.

"When there is little food, there is no choice but to go to sleep," he said.

Despite internal UN emails warning of severe malnutrition inside Tarik al-Sikka, UN officials in February and March 2018 repeatedly visited the detention centre to negotiate the future opening of the GDF.

AP saw emails confirming that by July 2018, the UNHCR's chief of mission was notified that companies controlled by al-Khoja's militia would receive subcontracts for services.

Migrants rescued at sea rest in the men's shelter aboard the Ocean Viking [Renata Brito/AP]

Yaxley, the spokesman for the UNHCR, emphasised that the officials the UN refugee agency works with are "all under the authority of the Ministry of Interior".

He said the UNHCR monitors expenses to make sure its standard rules are followed, and may withhold payments otherwise.

A senior official at LibAid, the Libyan government agency that managed the centre with the UN, said the contracts are worth at least $7 million for catering, cleaning and security, and 30 out of the 65 LibAid staff were essentially ghost employees who showed up on the payroll, sight unseen.

The UN centre was "a treasure trove," the senior Libaid official lamented. "There was no way you could operate while being surrounded by Tripoli militias. It was a big gamble."

An internal UN communication from early 2019 shows it was aware of the problem. The note found a high risk that food for the UN centre was being diverted to militias, given the amount budgeted compared to the amount migrants were eating.

In general, around 50 dinars a day, or $35, is budgeted per detainee for food and other essentials for all centres, according to two Libyan officials, two owners of food catering companies and an international aid worker.

Of that, only around 2 dinars is actually spent on meals, according to their rough calculations and migrants' descriptions.

Yaxley, the spokesman for the UNHCR, said the UN refugee agency monitors expenses to make sure its standard rules are followed, and may withhold payments otherwise. He also emphasised that the officials UNHCR works with are "all under the authority of the Ministry of Interior".

Despite the investigations into al-Khoja, Tarik al-Sikka and another detention centre shared a 996,000-euro grant from the EU and Italy in February.

At the Zawiya centre, emergency goods delivered by UN agencies ended up redistributed "half for the prisoners, half for the workers," said Orobosa Bright, a Nigerian who endured three stints there for a total of 11 months.

Many of the goods end up on Libya's black market as well, Libyan officials and international aid workers say.

IOM's spokeswoman said "aid diversion is a reality" in Libya and beyond, and that the UN agency does its best.

"Were it to become a regular occurrence IOM would be forced to re-evaluate the support it is providing to migrants in detention centres under DCIM despite our awareness that any reduction in this lifesaving assistance will add to the misery of the migrants," Msehli said.

All in all, Libya is run by militias... Whatever governments say, and whatever uniform they wear, or stickers they put ... this is the bottom line. Senior Libyan judicial official

Despite the corruption, the detention system in Libya is still expanding in places, with money from Europe.

At a detention centre in Sabaa where migrants are already going hungry, they were forced to build yet another wing funded by the Italian government, said Lamloum, the Libyan aid worker. The Italian government did not respond to a request for comment. Lamloum sent a photo of the new prison. It has no windows.

Tunisia laundering

The money earned off the suffering of migrants is whitewashed in money laundering operations in Tunisia, Libya's neighbour.

In the town of Ben Gardane, dozens of money-changing stalls transform Libyan dinars, dollars and euros into Tunisian currency before the money continues on its way to the capital, Tunis. Even Libyans without residency can open a bank account.

Informal exchange offices line a street on a border town of Ben Garden, southern Tunisia [Mosa'ab Elshamy/AP]

Tunisia also offers another opportunity for militia networks to make money off European funds earmarked for migrants. Because of Libya's dysfunctional banking system, where cash is scarce and militias control accounts, international organisations give contracts, usually in dollars, to Libyan organisations with bank accounts in Tunisia.

The vendors compound the money on Libya's black-market exchange, which ranges between four and nine times greater than the official rate.

Libya's government handed over more than 100 files to Tunisia earlier this year listing companies under investigation for fraud and money laundering.

The companies largely involve militia warlords and politicians, according to Nadia Saadi, a manager at the Tunisian anti-corruption authority. The laundering involves cash payments for real estate, falsified customs documents and faked bills for fictitious companies.

"All in all, Libya is run by militias," said a senior Libyan judicial official, who spoke on condition of anonymity for fear of risking his life. "Whatever governments say, and whatever uniform they wear, or stickers they put ... this is the bottom line."

Husni Bey, a prominent businessman in Libya, said the idea of Europe sending aid money to Libya, a once-wealthy country suffering from corruption, was ill-conceived from the beginning.

"Europe wants to buy those who can stop smuggling with all of these programmes," Bey said. "They would be much better off blacklisting the names of those involved in human trafficking, fuel and drug smuggling and charging them with crimes, instead of giving them money."