An Algerian military court cleared Said Bouteflika, the once-powerful brother of former president Abdelaziz Bouteflika, of conspiracy charges on Saturday following a retrial, the official APS agency reported.
The former presidential aide was long seen as the real power running the North African country after his brother suffered a debilitating stroke in 2013.
But he was detained in May 2019, a month after Bouteflika quit office following mass protests against his bid for a fifth term.
Said was sentenced with two former intelligence chiefs and a Trotskyist politician to 15 years in prison for "plotting against the authority of the army and the state", and a court later upheld that ruling.
But in November, the supreme court said the four would be retried after appeals.
"After deliberations, the court... rescinded the original ruling and acquitted all the defendants," lawyer Khaled Berghel told APS.
Despite being cleared, Bouteflika remains in custody and will be transferred to another prison as he awaits a separate trial over alleged corruption during his brother's rule, a court official said.
Bouteflika and the three others acquitted with him were accused of meeting in March 2019 and plotting to "destabilise" the army's high command, then headed by General Ahmed Gaid Salah, which was publicly demanding that the president step down.
- String of graft trials -
Said Bouteflika's co-defendants included General Mohamed Lamine Mediene, known as "Toufik", who headed the powerful Department of Intelligence and Security for 25 years, and his former right hand General Athmane Tartag.
Also on trial was Louisa Hanoune, who had served as secretary general of the Trotskyist Workers' Party.
Abdelaziz Bouteflika had been Algeria's longest-serving president but was forced to resign in April 2019 after losing the backing of the army amid enormous street protests against his decision to seek a fifth term.
The Hirak protest movement kept up the pressure, demanding deep-rooted reforms of the ruling system in place since Algeria's independence in 1962, and only suspended its rallies when the coronavirus pandemic hit.
Following Bouteflika's departure, authorities launched a string of investigations against high-ranking former officials and business figures, several of whom have been convicted.
They include Ali Haddad, a construction mogul and former head of Algeria's main employers' organisation, who was convicted of illegally obtaining "privileges, advantages and public contracts", as well as conflict of interest and squandering public funds.
Said Bouteflika was implicated in several of the cases.
But some see the trials as little more than score-settling between rival clans among the ruling elite rather than a genuine reform effort.
They take place in a climate of repression that has also seen dozens of pro-democracy activists, journalists and bloggers arrested in recent months.