A man whose rape conviction was quashed after it was discovered his accuser had “manipulated” Facebook messages between them has lost his High Court bid for compensation.

Danny Kay was sentenced to four-and-a-half years in prison in 2013 after he was convicted of rape.

During his trial at Derby Crown Court, jurors were shown Facebook messages between Mr Kay and the woman, which Mr Kay maintained were incomplete.

He had asked prosecutors to obtain the full Facebook exchanges from his accuser, who cannot be named, believing he could no longer access the messages from his account.

However, the full messages were found by Mr Kay’s family and lawyers after his sentencing and were used as part of a successful Court of Appeal challenge in 2017.

Overturning his conviction, the Court of Appeal found there were 29 messages sent and received that had been selectively deleted, leading to “a number of significant and misleading impressions”.

Mr Kay brought a High Court claim after he was denied miscarriage of justice compensation by the Ministry of Justice.

At a two-day hearing in May, the court heard the application for compensation was denied as the deleted Facebook messages did not demonstrate beyond a reasonable doubt that Mr Kay did not commit the offence.

Mr Kay’s lawyers argued that the department had not properly considered how the woman’s manipulation of the messages undermined her credibility and the context of the discussions.

However, in a judgment on Friday, Lady Justice Macur rejected Mr Kay’s claim.

She said: “The complainant’s lack of credibility on the Facebook record did not of itself establish what happened on the evening in question.

“Indeed, as noted above, the substance of the retrieved messages did not explicitly or implicitly discuss the act of sexual intercourse or the issue of consent, nor establish that the nature of the ongoing interaction was inconsistent with an offence of rape.

“Instead, the full Facebook record, and the fact that it had been manipulated by the complainant, was evidence of obvious materiality to the jury’s assessment of the complainant and the claimant’s credibility.”

Lady Justice Macur, sitting with Mr Justice Foxton, added: “I have no doubt that this claimant has suffered greatly because of his conviction and imprisonment.

“However, for compensation to be payable, the newly discovered fact admitted into the appeal proceedings must positively disprove the commission of the offence beyond reasonable doubt, and not merely undermine the safety of the conviction.”