Many changes Poland's new conservative government has made to the functioning of the top legislative court are unconstitutional, judges have ruled.
However the government has indicated it will not recognise the Constitutional Court's judgment.
The new rules increase the number of judges needed for a ruling and change the order in which cases are heard.
The court's verdict means the country is heading towards a constitutional crisis, observers say.
The government is already coming under scrutiny from both Brussels and Washington for allegedly endangering democratic checks and balances, says the BBC's Adam Easton in Warsaw.
Since coming to power in October, the Law and Justice party (PiS) has regularly come to blows with the media and the opposition.
Late last year the government passed legal amendments changing the way the Constitutional Court operates.
They require a two-thirds majority of the 15 judges to support a ruling for it to be valid, and also stipulate a quorum of 13 judges for rulings to be valid.
The PiS says the changes are needed to reflect the new balance of power after its landslide election win last year, Reuters news agency reported.
Prime Minister Beata Szydlo said the Constitutional Court's judgment would not be legally valid because the court had failed to adhere to the rule changes introduced by her party.
But critics say the changes mean the court is now unable to examine government legislation.
"Dramatically limiting the court's ability to function independently and thoroughly contravenes Poland's (political) system and cannot be tolerated," said Judge Stanislaw Biernat, announcing the ruling after a two-day session.
This issue has sparked protests against and in support of the government's stand.
The amendments to the law governing the court are being investigated by the European Commission for a possible breach of the rule of law.
Last month, a draft report by the Council of Europe - a human rights watchdog - said the changes make it extremely difficult for the court to take decisions, thereby endangering the rule of law.