The opposition calls the arrest of the judges, a purge and the global community has condemned it. Worldwide and domestic flights, seaplanes and all modes of transport are in operation, the Maldives government said on February 6.
Yameen later accused the pair of plotting to overthrow him.
Later, former dictator and opposition politician Maumoon Abdul Gayoom was seen on a mobile phone video taken by his daughter being quietly escorted from his home by security forces, hugging friends and family and waving to supporters before being driven away.
The Maldives is made up of 26 coral atolls and 1,192 islands.
Yameen called a 15-day state of emergency, deepening a political crisis.
India - which has traditionally viewed itself as the island nation's "big brother" - is not happy. Prez. Gayoom. We request a physical presence. But he refused to be drawn on what exactly this meant. Under the emergency measure, the government has assumed sweeping powers and curbed judicial powers or immunity.
The detained opposition leader, Maumoon Abdul Gayoom, is the estranged half-brother of the current president Yameen Abdul Gayoom.
Bangladesh 81 for 3 wickets, trail by 119 runs: First Test
Spare a thought for the left-arm spinner Taiujul Islam, who alone sent down 67.3 overs, picking up figures of 4/219 for his toil. The duo shared 135 run stand for the fourth wicket before Mehedi Hasan (3-174) had Roshen caught behind.
"Certain rights will be restricted (but) general movements, services and businesses will not be affected", the president's office said in a statement about the emergency."The government of Maldives wishes to also assure all Maldivians and the worldwide community that the safety of all Maldivians and foreigners living in and visiting the Maldives, will be ensured", it said. "We must remove him from power".
"The decision of the Supreme Court of the Maldives to annul criminal proceedings against leading politicians and admit unfair trials against them is a positive step towards restoring the democratic principles in the country", it read.
A Maldivian minister to the UN, Jeffrey Salim Waheed, called his intervention "treason" and "the single biggest attempt to undermine the Maldives' sovereignty". Nasheed, who is living in self-imposed exile, was sentenced to 13 years in jail on a terror charge widely criticised as politically-motivated. The ruling also ordered the government to reinstate 12 legislators who were sacked for defecting to the opposition, potentially paving the way to impeach the president.
The new order was signed by the three remaining judges of the Supreme Court.
What does this mean for tourists?
What happens next? Yameen is facing worldwide pressure to follow the court order and reinstate the opposition.