Supporters of ousted PM Ranil Wickremesinghe had gathered outside the court ahead of the verdict. Photo: AFP
Sri Lanka's Supreme Court has suspended the president's move to dissolve parliament, as a political crisis in the island nation deepens.
President Maithripala Sirisena shocked the nation by sacking parliament and calling snap elections on Friday.
The dramatic decision came two weeks after Mr Sirisena fired his prime minister and replaced him with the country's former leader.
But his actions have been called unconstitutional.
Ranil Wickremesinghe, the ousted PM, had refused to give way to his named successor, Mahinda Rajapaksa, and had called for MPs to vote on who they believed was the rightful premier.
Correspondents said the president and Mr Rajapaksa decided to called the snap election because they did not have enough support in parliament for their new government.
Mr Wickremesinghe's United National Party (UNP) said the move was illegal and it and other parties filed petitions with the Supreme Court.
Its order means that elections, announced for 5 January, have been put on hold.
Hundreds of heavily-armed police had been deployed to the court ahead of Tuesday's decision and UNP supporters set off firecrackers in celebration as news of the order filtered out.
"The people have won their first victory. Let's go forward and re-establish the sovereignty of the people in our beloved country," tweeted Mr Wickremesinghe.
Namal Rajapaksa, an MP and son of Mahinda Rajapaksa, responded by saying the court had not made a "final decision".