The Higher People's Court of Jilin Province quashed the conviction of Liu Jiqiang, 52, and ordered his release.
This is the latest wrongful murder verdict to be corrected as China works to improve judicial justice and transparency, leading to the retrial of thousands of cases since 2013.
Liu was arrested in 1998 in connection with the murder of his girlfriend on Valentine's Day that year in Jilin. In 1999, a local court convicted Liu and handed down a death penalty with a two-year reprieve.
Liu appealed but failed in two retrials in 2002 and 2003.
During the third retrial, which began on April 19, Liu's lawyers said his conviction was based on insubstantial proof and that his confession was obtained as a result of torture and illegal questioning.
The court also said Liu's initial confession was invalid and that the previous convictions had been supported by insufficient evidence.
Fu Dazhong with Jilin Academy of Social Sciences said the pressure on local Chinese police to solve homicide cases resulted in a number of miscarriages of justice, and Liu's case should serve as a wake-up call.
China saw a number of false convictions corrected in recent years. One high-profile case was that of an 18-year-old man named Huugjilt who was executed in 1996 for the rape and murder of a woman. He received a posthumous pardon in 2014 after a serial rapist and killer admitted to the crime.
In another case, Nie Shubin, 21, was executed in 1995 for the rape and murder of a woman in Hebei Province, only to have another man confess to the crime years later. The case is still being reviewed.