Osman Matammud, 22, was convicted of murder and multiple counts of torture on the basis of testimony from migrants after he was recognised by chance outside a migrant centre in Milan.
Matammud, who tried to pass himself off as a regular asylum seeker, was arrested in September 2016 after being reported to authorities for using torture to extort money from migrants in a transit camp in Bani Walid, a town in the Libyan desert.
Migrants from sub-Saharan Africa often spend time in such camps while waiting for their families to pay more money to people traffickers who have promised to get them to Europe. Torture is used to speed up and sometimes increase the payments.
A total of 17 victims testified against Matammud in the Milan court, with some saying he had beaten people to death and let others die from a lack of food, water or medical treatment.
Two young women told the court he had raped them.
"Matammud was a case of someone losing all moral compass, of being overcome by a delirious sense of power as a result of having the lives of others in his hands," lead prosecutor Marcello Tatangelo told the trial last month.
The young Somali man claimed he was just like any other migrant arriving in Italy and had been himself the victim of violent attacks in Libya.
His lawyer portrayed Matammud as being caught up in a war between rival Somali clans. "I've told the truth, I've not lied, nor have I committed any crime," Matammud said in his final appeal.
Testimonies by the victims left a mark on the investigators. "In a 40-year career, I have never come across horror on the same level, and you have to imagine that what happened in Bani Walid is taking place in every camp," another prosecutor, Ilda Boccassini, said in January.