Sri Lanka's Supreme Court has ruled that an attempt to impeach the chief justice is unconstitutional.
A parliamentary select committee found Shirani Bandaranayake guilty of professional misconduct in December.
Mrs Bandaranayake denies allegations of financial and professional wrongdoing. She could be dismissed after parliament votes on the report in January.
Critics say the impeachment charges are politically motivated and challenge the judiciary's independence.
But the Supreme Court on Thursday declared that a parliamentary committee does not have the legal power to investigate allegations against the chief justice.
In the ruling, the judges said it "has no legal power or authority to make a finding adversely affecting the legal rights of a judge," the Associated Press news agency reported.
Information Minister Keheliya Rambukwella is quoted by AP as saying it would be "premature and unfair" to comment on the ruling until the speaker of parliament has expressed his views.
Civil society figures and lawyers have accused the government of trying to stifle the independence a judiciary which has made rulings unfavourable to Sri Lanka's powerful president.
The government has denied pursuing a vendetta.