The Supreme Court in Indonesia has sentenced the minority Christian governor of Jakarta, Basuki Tjahaja Purnama, to two years in prison after he was found guilty of blasphemy against Islam. The controversial case was seen as a test of religious tolerance in the world's most populous Muslim country.

Purnama, also known by his Chinese name Ahok, was hauled into court last year to face trial for remarks he made in September 2016 while campaigning for re-election.

Hardline Muslim groups alleged that the outgoing governor had insulted Islam and dishonoured the Quran by quoting a verse during the gubernatorial election campaign to boost his chances of winning the governor's post for a second term. Although Purnama apologised for passing offending remarks, he denied committing blasphemy.

Massive protests erupted across the capital for a few weeks in November and December as angry demonstrators demanded his resignation and subsequent arrest.

Almost five months after the case began, a five-judge bench found the 50-year-old had deliberately committed blasphemy and hence was guilty of the charge. However, the panel rejected the call by prosecutors to put Purnama on two-year probation. They have instead sentenced him to two years in jail.

Protests outside court

Around 15,000 police personnel have been deployed outside the court premises where Purnama's sentencing was pronounced to prevent an outbreak of violence. Protesters for and against the governor had gathered outside the court ahead of the verdict.

His opponents demanded that Purnama be sentenced to a longer prison term, while his supporters held rallies calling for his acquittal. They even put up a display on the road saying "Save Ahok".

Basuki Tjahaja Purnama
Jakarta's first non-Muslim governor, Basuki Tjahaja Purnama also known as Ahok, arrives at court for his verdict in Jakarta, Indonesia on 9 May Reuters/Bay Ismoyo/Pool

Purnama told the court that he would be appealing the sentence, local media reports said. His appeal will be heard at a later date.

Purnama is the first ethnic Chinese Christian to govern the Indonesian capital. His term ends in five months.

In a bitterly fought gubernatorial election on 19 April, he was defeated by his conservative Muslim rival Anies Rasyid Baswedan, a former education minister. Purnama conceded defeat following the divisive election that was marred by religious tensions.