LONDON — A Scottish court ruled on Wednesday that Prime Minister Boris Johnson’s decision to suspend Parliament was unlawful, a remarkable rebuke of the government’s hard-line tactics in trying to pull Britain out of the European Union.
A panel of three judges in the Court of Session found that the decision to send lawmakers home for five weeks at the height of the Brexit crisis was “unlawful because it had the purpose of stymying Parliament.”
The main reason for the suspension, known technically as “prorogation,” was Mr. Johnson’s desire to free himself of parliamentary oversight as he pursued an abrupt Brexit, a summary of the ruling said.
“This was an egregious case of a clear failure to comply with generally accepted standards of behavior of public authorities,” the summary said. “It was to be inferred that the principal reasons for the prorogation were to prevent or impede Parliament holding the executive to account and legislating with regard to Brexit, and to allow the executive to pursue a policy of a no-deal Brexit without further parliamentary interference.”
The decision set up a showdown next week at the Supreme Court in London, which had already said it would review the case and take up the question of whether to halt the suspension of Parliament.
The British government said it was “disappointed” by the decision and would file an appeal, calling the suspension “legal and necessary.” The group of lawmakers who brought the case called for Parliament to be immediately reconvened.
“Our understanding is that unless the Supreme Court grants an order in the meantime, Parliament is unsuspended with immediate effect,” said Jolyon Maugham, the lawyer whose group funded the challenge.
But that remained in doubt. The office of the speaker of the House of Commons said decisions about reconvening Parliament rested in the government’s hands.
The Scottish Court ruling conflicted with a separate decision by the High Court in London last week that the suspension was legal. The Scottish Court also reversed a decision of its own last week not to intervene in the case.
In reaching their decision, the judges reviewed documents detailing the government’s deliberations before suspending Parliament. On that basis, they said, the only explanation for the decision to suspend Parliament was the government to keep its Brexit policy from being scrutinized by lawmakers largely opposed to a no-deal Brexit.
Parliamentary oversight, the summary of the ruling said, is “a central pillar of the good governance principle enshrined in the constitution.”
The ruling said that the court would make an order declaring that the prime minister’s advice to Queen Elizabeth II asking her to suspend Parliament, and the suspension of Parliament itself, was unlawful “and is thus null and of no effect.”
That created uncomfortable questions about whether Mr. Johnson had deliberately misled the queen, who acts on the advice of the prime minister.
Mr. Johnson, who is committed to pulling Britain out of the European Union by Oct. 31, with or without a deal governing future relations, decided to send Parliament home as lawmakers began making clear that they would try to block his path to an abrupt Brexit.
While it is within a prime minister’s rights to suspend Parliament, those suspensions usually last for only a few days. Scholars called it constitutionally suspect, if not downright unconstitutional, though many doubted that the courts would intervene.
The suspension began on Tuesday, and it was scheduled to prevent Parliament from sitting until mid-October, only weeks before Britain could crash out of the European Union without a deal.
Lawmakers moved quickly enough before the suspension that they passed a law seeking to force Mr. Johnson to ask for a Brexit delay if he did not have a deal in place by late October, though Mr. Johnson has vowed that he would never ask for an extension.