Sex outside of marriage is illegal in the UAE, and a woman and man have just learned that the hard way.

A British woman is appealing a one-year jail sentence handed down after it was revealed that she had consensual sex with a Pakistani man. 

The woman and the man involved have different accounts of the story, but both were given the same sentence, according to Gulf News.

Last year, the woman flew to Dubai and eventually had consensual sexual intercourse with the man. However, according to the man, the two were married in a private ceremony in Sharjah with a Pakistani religious leader.

The woman disputes this claim, saying the two were never married. According to her, an issue arose after she returned to the UK and decided to marry another man. Her former lover began to send threats and called her new fiancé's family, claiming he and the woman were already married.

The man went even further, threatening to kill the woman if she married the new man, according to what she told prosecutors.

Dubai skyline Source: WikiMedia

In an effort to end the threats, the woman and her potential future father-in-law then flew to Dubai to file a formal legal complaint against the Pakistani man.

However, during the investigation, the authorities were made aware that the couple had previously had sex. Both were promptly arrested and sentenced for the crime.

When they appeared in court, both defendants pleaded not guilty but were sentenced to prison. Now the decision is being appealed, with a request for leniency.

The couple's story comes just a week after news broke of a non-married Japanese couple arrested for having sex on a beach in Dubai.

The court handed the man and woman a one-month suspended imprisonment and also gave the couple a deportation order. The couple appealed their primary judgment and will appear before the Appeal Court in September.

Earlier this year, it was also revealed that an unmarried couple in Abu Dhabi had been arrested after going to the hospital and discovering they were pregnant.