(CNN) Former Egyptian President Hosni Mubarak was acquitted Thursday of charges he played a role in the killing of protesters during the Arab Spring uprising that led to his ouster, according to state-run news agency Al-Ahram.
The Court of Cassation verdict is final and Mubarak is now free, Al-Ahram said. He has been confined at Maadi Military Hospital for treatment since 2012.
Mubarak, 88, dominated the nation for three decades as president but went through a series of criminal trials after being forced from office in 2011.
Amnesty International said at least 840 people were killed and more than 6,000 injured during the 18 days of street protests in Egypt.
Mubarak was convicted in 2012 of ordering the deaths of protesters and sentenced to life in prison.
But in January 2013, the Court of Cassation overturned Mubarak's conviction and ordered a retrial.
That same court also upheld the acquittal of other defendants, including former Interior Minister Habib El-Adly and four of his aides, Al-Ahram said.
Mubarak was retried in 2014 but the court acquitted him and the co-defendants, saying the prosecution's initial decision to charge Mubarak lacked legal basis, Al-Ahram said.
In 2015, judges ordered him to be tried for a third time for the killings.
The Court of Cassation is the highest court in criminal litigation in Egypt, so its decision is final.
Mubarak has been hospitalized for long periods with heart problems and stomach cancer since leaving office, sometimes appearing in the courtroom on a stretcher or in a wheelchair.
Al-Ahram said there was only one "final conviction," on corruption charges.
In January 2016, the Court of Cassation rejected an appeal by Mubarak and his two sons, Gamal and Alaa, of their conviction for embezzling $17.9 million allocated for the renovation of the presidential palace.
The Mubaraks were ordered to pay 125 million Egyptian pounds ($16 million) and sentenced them to three years in prison. The court credited the Mubaraks for time served.
Mubarak, a military hero because of his actions during the 1973 Yom Kippur War with Israel, was elected president in 1981.