The Court of Appeal ruled that the conviction was unsafe after new evidence showed that John Roberts, 35, had a fragile, vulnerable and suggestible mental condition and tended to be compliant with people in authority.
The judges said a "grave injustice" was done to Mr Roberts who was arrested at his home in Shrewsbury, Shropshire, at the age of 19. The also criticised police from the West Mercia force for not providing him with a solicitor for five hours while he was being questioned and for holding him "incommunicado" until he suddenly changed his plea and "confessed".
The case is seen as one of the worst and most tragic miscarriages of justice from the period before the Police and Criminal Evidence Act regulated the work of detectives.
His conviction was only overturned after his mother managed to find a sympathetic lawyer who spent several years working for his release for free.
Mr Roberts, whose case was highlighted by The Independent in January, and a man named Richard Evans, then 23, were found guilty in February 1983 of shooting dead Daniel Sands.
The body of Mr Sands was discovered in a makeshift grave in an orchard at Barleycorn Farm in the village of Grinshill, 10 miles from Shrewsbury in March 1982, after he had been missing for 18 months. Three days later, Mr Roberts was arrested and within hours, he had admitted to the murder.
Roberts, who was 17 at the time of the offence, was detained during Her Majesty's pleasure, and Evans was given life. The confession was the main evidence against Roberts.
Mr Roberts was released last August pending the referral back to court by Jack Straw, the Home Secretary, following the dismissal of an appeal in 1984. He remained in jail for several extra years because he refused to admit his guilt.
The Court of Appeal said that since the trial medical science and the law knew much more about the phenomenon of false confessions. "The expert evidence is agreed as to the excessively compliant personality of this appellant, and his consequent vulnerability. He pre-eminently needed the attendance and support of a solicitor. There were no grounds for holding him incommunicado."
The confession was considered inadmissible and there was no case to answer, said Lord Justice Henry, sitting with Mr Justice Ognall and Mr Justice Toulson. "We are conscious that the unreserved apology we offer him ... will not give him back those lost years of life and liberty," they added.
After the judgment, Mr Roberts said that it took until 1988 to get a solicitor, James Wilson, and counsel who were prepared to take his case on.
"Basically, the police really intimidated me and badgered me constantly. No matter what I said, they were saying something else. At the end I really gave up as no one was listening."
Safina Din, from JM Wilson solicitors in Birmingham, said they would be considering claiming compensation for the miscarriage of justice.