The atoll nation's joint opposition welcomed the surprise ruling, which has also granted them a parliamentary majority, and demanded that President Abdulla Yameen step down.
"The Supreme Court's verdict effectively ends President Yameen's authoritarian rule," the opposition said in a statement.
The Maldives' popular image as an upmarket holiday paradise had been severely damaged by a major crackdown on dissent under Yameen, who has overseen the jailing of almost all the political opposition.
Nasheed, who is living in self-imposed exile, was sentenced to 13 years in jail on a terrorism charge widely criticised as politically motivated.
The court ordered authorities to "immediately free the jailed leaders until a court of law sentences otherwise".
The Maldives police said in a tweet that it will abide by court orders, but within minutes the government announced the sacking of police chief Ahmed Areef.
Attorney General Mohamed Anil told a hurriedly summoned press conference at the military headquarters in the capital that Yameen sacked the police chief because he was uncontactable after the court order.
The court also restored 12 dissident members of parliament who had been controversially expelled for defecting from Yameen's party. The latest order gives Yameen's opponents a majority in the 85-member parliament.
Hundreds of supporters of Nasheed's opposition Maldivian Democratic Party (MDP) took to the streets today to celebrate the court decision.
Several activists gathered outside an MDP office and chanted slogans demanding Yameen's impeachment.
It was not immediately clear when the political prisoners would be freed or what prompted the action by the court.
Opposition figures including Nasheed and another five dissidents named in today's order have united against the president.
They accuse him of "unprecedented corruption, including unjust enrichment from appropriation of state properties and funds for personal benefit, for the benefit of his family and political associates".
Among those who petitioned the top court was Yameen's half-brother and former president Maumoon Abdul Gayoom, whose legislator son, Faris Maumoon, had been arrested. He was among those whose release the court ordered.
Another key dissident, Qasim Ibrahim, who helped Yameen in the 2013 run-off election, was also ordered to be released.
He, however, is not in the Maldives. Like Nasheed, he also obtained prison leave for medical treatment and has remained in Europe.
Almost all key opposition leaders and a number of ruling party dissidents have either been jailed or gone into exile in the Maldives in recent years under Yameen.
The president took office in 2013 after winning a controversial run-off vote against Nasheed.
Last year he announced his intention to return and run for president in elections due later this year, but he was prevented by the criminal conviction against him.
A UN panel has ruled that his imprisonment was illegal and asked the regime to pay him compensation -- an order ignored by Yameen's administration.
The United States has said democracy is under threat in the strategically located archipelago of 340,000 Sunni Muslims, which sits on key international shipping lanes.
Disclaimer: No Business Standard Journalist was involved in creation of this content
You’ve reached your limit of {{free_limit}} free articles this month.
Subscribe now for unlimited access.
Already subscribed? Log in
Subscribe to read the full story →
Smart Quarterly
₹900
3 Months
₹300/Month
Smart Essential
₹2,700
1 Year
₹225/Month
Super Saver
₹3,900
2 Years
₹162/Month
Renews automatically, cancel anytime
Here’s what’s included in our digital subscription plans
Exclusive premium stories online
Over 30 premium stories daily, handpicked by our editors


Complimentary Access to The New York Times
News, Games, Cooking, Audio, Wirecutter & The Athletic
Business Standard Epaper
Digital replica of our daily newspaper — with options to read, save, and share


Curated Newsletters
Insights on markets, finance, politics, tech, and more delivered to your inbox
Market Analysis & Investment Insights
In-depth market analysis & insights with access to The Smart Investor


Archives
Repository of articles and publications dating back to 1997
Ad-free Reading
Uninterrupted reading experience with no advertisements


Seamless Access Across All Devices
Access Business Standard across devices — mobile, tablet, or PC, via web or app
