Appeal judges in Edinburgh ruled that Ryan McCallum, 32, should benefit from the Cadder ruling, which outlawed the use of evidence obtained during such interviews.
McCallum was sentenced to five years in prison after a woman told a trial he had attacked her in a Glasgow flat in March 2008 following a wine and cocaine-fuelled sex encounter.
The court heard he ripped her clothes and forced himself on her.
McCallum admitted there had been a struggle but claimed the woman had been flirting with him and willing to have sex.
He told how they had been drinking and snorting cocaine that evening.
Injuries to her wrists and the damage to her clothes happened when they quarrelled afterwards, he told the trial at the High Court in Glasgow in May 2009.
A jury found him guilty but solicitor advocate John Carroll, defending, told the Court of Criminal Appeal in Edinburgh that McCallum had suffered a miscarriage of justice.
He told Judge Lord Eassie, sitting with Lord Menzies and Lord Wheatley, that prosecutors at the trial had used what McCallum told police to attack his credibility by pointing out inconsistencies.
The lawyer said there had been 42 references to the interviews in an attempt to brand McCallum a liar.
Lord Eassie noted that about one-third of the prosecutor's closing speech to the jury had been based on the interviews.
Mr Carroll claimed that McCallum had been denied a fair trial because of the Supreme Court decision two years ago in the case of Peter Cadder, which ruled that it was a breach of human rights to allow an accused to be detained and interviewed by police without a chance to get legal advice first.
The ruling prompted emergency legislation to be pushed through Holyrood to ensure Scotland complied with the European Convention on Human Rights.
Advocate depute Alex Prentice, QC, told the Edinburgh appeal judges that the Crown accepted the Cadder ruling made the interview evidence inadmissible.
However, he claimed there were other reasons to accept the woman's account of events, so the conviction should stand.
Lord Eassie, giving yesterday's decision, agreed with Mr Carroll that without the prosecution's use of the question and answer session with police, the outcome of the trial could have been different.
McCallum's trial and sentence happened before the legal arguments sparked by Peter Cadder – accused of an assault in Glasgow – led to a change in the law.
But the Scottish Criminal Cases Review Commission, which investigates possible miscarriages of justice, decided that McCallum's conviction could be challenged.
It is thought that he was the first to benefit from such a decision.
The Cadder ruling has led to hundreds of cases being abandoned and some cases being tried again under the new rules.
It has also been blamed for a fall of around one-third in the number of rape and attempted rape convictions in Scottish courts.