Former Maldives president Mohamed Nasheed has been convicted of a terrorism charge by a criminal court and sentenced to 13 years in prison.

The three-judge bench on Friday unanimously found Nasheed guilty of ordering the arrest of a chief judge in January 2012 when he was leader of the Indian Ocean island nation.

"Nasheed is found guilty of arresting and illegally detaining judge Abdulla Mohamed," judge Abdulla Didi told the court in a verdict just before midnight. Nasheed was then taken to Dhoonidhoo prison, near the capital Male.

Nasheed has denied ordering the arrest. His supporters say the charges are aimed at eliminating him as a challenger against incumbent President Yameen Abdul Gayoom in the 2018 presidential election.

A statement released by his office on Friday called the trial "blatantly politicised".

"President Nasheed was repeatedly denied legal representation, denied the right to appeal, his defence witnesses were prevented from taking the stand, and prosecution witnesses were routinely coached by the judges and the police," it said.

At court, the former president called on Maldivians to "confront the dictatorial power of this regime".

"The Maldivian judiciary is full of corruption and disgrace. Judges are routinely accepting the vile money of bribery," said Nasheed.

"These judges have no fear of the day of judgment, and no shame in this world. The consequence of their actions is injustice to the public, and the thwarting of this country’s development."

Nasheed's Maldivian Democratic Party (MDP) said the verdict dealt a blow to the young democracy seven years after it embraced multi-party elections following three decades of rule by former strongman Maumoon Abdul Gayoom.

"Democracy jailed for 13 years on March 13, 2015," declared MDP spokeswoman Shauna Aminath. "Nothing good will come out of this. It's a sad, sad, sad day for the Maldives," she added.

The ruling came four days after Nasheed's lawyers quit in protest against what they called a biased trial aimed at destroying his political career.

Nasheed, the country's first democratically elected leader, was originally cleared of the charge last month but a few days later the prosecutor general had him re-charged and arrested under tough anti-terror laws.

Before the brief hearing in February in which the court denied him bail, police forcibly dragged Nasheed into court, refusing him to speak to journalists and ignoring his plea to be allowed to walk in himself.

Global concern

The United States and regional power India had voiced concern over the charges and attempts to keep him out of politics.

The controversial trial went on despite widespread criticism, with current President Abdulla Yameen denying that the move was politically motivated.

Hundreds of supporters have been protesting in the capital island Male on a regular basis since Nasheed's arrest last month.

Nasheed resigned as Maldives leader in February 2012 after a mutiny by police and troops that followed weeks of protests over the arrest of judge Mohamed on corruption allegations.

He has maintained that he was innocent and he was wrongfully charged. Nasheed was denied medical attention while in police custody, his party has said.

The judge was arrested after he released a detained opposition politician, and Nasheed's administration accused him of political bias and corruption.