Maldives ex-president Mohamed Nasheed has appeared in court to face charges that he illegally detained a senior judge while in office.

The case is the latest showdown since Nasheed left office earlier this year. He claimed the military forced him out.

Hundreds of Nasheed supporters protested outside the court as police brought him inside Tuesday. The protesters accused the government of arresting him on politically motivated charges.

Police arrested Nasheed on Monday after he twice ignored court summons and also defied an order preventing him from leaving the capital, Male.

Nasheed's order to arrest senior judge earlier this year prompted weeks of public protests leading to his resignation.

He claimed he was forced to step down under threat by the military. A inquiry commission later ruled his resignation was legal.