The case arose from criminal proceedings at the Pest Central District Court against a Swedish national in Hungary who spoke no Hungarian.
Because Hungary has no official register of translators and interpreters, the judge ruled that the accused's right to be informed of his rights might be infringed. He referred the case to the ECJ.
Hungary's Supreme Court ruled that this request to the ECJ was unlawful after prosecutors appealed.
The judge in the initial case also faced disciplinary proceedings — which have since been dropped — under the Supreme Court ruling.
As a result, the same judge asked the ECJ for an additional ruling about whether the Supreme Court decision was compatible with EU law.
What the ECJ ruling said
The Luxembourg chamber said that, under EU law, national judges could not be censured for asking the ECJ for guidance.
"EU law precludes disciplinary proceedings from being brought against a national judge on the ground that he or she has made a reference for a preliminary ruling to the Court of Justice," the EU court said.
The judges said such disciplinary proceedings could undermine judicial independence.
Transgender boy against anti-LGBTQ law
It also said that, under the system of cooperation between the national courts and the ECJ, the Supreme Court in Hungary could not rule the judge's referral about the translation issue as unlawful.
"The principle of the primacy of EU law requires the lower court to disregard the decision of the supreme court of the member state concerned," it said.
On the translation issue, the court said member states "must take specific measures ensuring, first, that the quality of the interpretation and translations is sufficient to enable the suspect or accused person to understand the accusation against him or her."
"A national court may conclude that, either because the interpretation provided was inadequate or it is impossible to ascertain its quality, a person has not been informed, in a language which he or she understands, of the accusation against him or her."
Partnering up with Poland
While Hungary sometimes follows the rulings of the ECJ, it has also ignored them.
Hungary has formed a united front with Poland against the European Union over questions of the rule of law, press freedom and migration policy.
The two countries have mutually pledged to veto EU moves that would punish the other.
The EU last week wrote to Warsaw and Budapest to launch a process that could lead to both being deprived of funds over threats to the EU legal order.
In the case of Hungary, the European Commission is understood to have expressed concerns over public contracts, conflicts of interest and corruption in the spending of EU funds.