Hungarian PM Viktor Orban has declared victory in a referendum on mandatory EU migrant quotas, despite a low turnout that appeared to render it invalid.
Nearly 98% of those who took part supported the government’s call to reject the EU plan.
But only 43% of the electorate voted, short of the 50% required to be valid.
A government spokesman said the outcome was binding «politically and legally» but the opposition said the government did not have the support it needed.
Mr Orban urged EU decision makers to take note of the result and said he would change Hungary’s constitution to make the decision binding.
The controversial EU plan to relocate 160,000 migrants across the bloc would mean Hungary receiving 1,294 asylum seekers.
Ferenc Gyurcsany, leader of the opposition Democratic Coalition, said the low turnout showed that most people did not support the government.
«According to this result with such low turnout, the people do not support the government. And this is good. The migration issue outreaches Hungarian borders.»
But a government spokesman said the result could not be regarded as invalid.
«The government initiated the referendum, so both politically and legally the outcome is binding,» he said.
«The 50% would have made a difference because parliament could have no alternative but to make a decision. But parliament is behind the government regarding the decision. This is a reinforced mandate for the government.»
Analysis – BBC News Europe editor, Katya Adler
The referendum result is both a crushing defeat and an emphatic victory for Hungary’s prime minister.
On the one hand, Viktor Orban led a prominent, expensive and relentless anti-EU and anti-migrant referendum campaign but failed to persuade most Hungarians to vote.
On the other hand, those who did vote sided with him almost unanimously, allowing him to trumpet that a higher percentage of Hungarians voted against EU migrant quotas than voted for EU membership 13 years ago.
Mr Orban says he is leading what he calls a counter-revolution against EU centralisation, a pushback against Brussels bossiness. He views himself as the man of the moment, speaking for the people of Europe.
He had hoped other countries would follow suit and hold their own referendum on migrant quotas. In fact other EU countries are simply ignoring the quotas.
What Hungary’s prime minister is not calling for is «Huxit» – a Hungarian exit from the EU. Mr Orban is all too aware the his economy relies on EU subsidies.
During last year’s migrant crisis, Hungary became a transit state on the Western Balkan route to Germany and other EU destinations.
In an effort to curb the influx, it sealed its border with Serbia and Croatia. The measure was popular at home but criticised by human rights groups.
Voters were asked: «Do you want the European Union to be able to mandate the obligatory resettlement of non-Hungarian citizens into Hungary even without the approval of the National Assembly?»
The EU proposal was meant to ease pressure on Greece and Italy, the main entry points for migrants and refugees into the bloc.
In December Hungary filed a court challenge against the EU plan, which would see relocations over two years.