At the time of writing, 80 percent of the vote had been counted and Denmark had rejected proposals to "opt-in" to certain European Union police and justice policies.
The "no" vote was ahead with 53.7 percent in a poll with an unexpectedly high turnout of some 72.8 percent of eligible voters in a contest which tested for the first time in 15 years whether the nation wanted further EU integration.
The last time Denmark went to the polls on an EU issue had been in 2000, when they had refused to join the euro. Before that, it had been in 1993, for which four so-called "opt-outs" from EU integration had been negotiated after the Maastricht treaty had been rejected a year previously.
An odd twist to the referendum was that the Danes themselves were not being asked whether they wanted to adopt the 22 EU laws required for Europol participation. Instead, the people were being asked to give parliament the authority to dispose of the opt-outs.
This has raised trust issues which DF has been able to exploit. The central point has been the claim that a "yes" vote would mean the Denmark will have to "wave goodbye to ever having controls at the border with police and customs officers without asking the EU for permission".
Here, the "no" campaign has argued that participation could be arranged on the same basis as non-EU member Switzerland. But it was also argued that parliament could not be trusted on the other opt-ins, include the EU's asylum policy, which could be conceded without further consultation.
Very much mirroring the sort of slogans we've been using here, Kristian Thulesen Dahl, the Danish People's (DF) party leader has been saying: "Danes are saying yes to cooperation but no to relinquishing more sovereignty to Brussels".
As always, the Danish government and the major political parties had urged a "yes" vote. However, their campaign has been considered lacklustre while the DF has used the referendum to send an anti-EU message under the slogan, "More EU? NO THANKS".
Although Prime Minister Lars Løkke Rasmussen had vowed that Denmark would remain outside the asylum rules and promised Danes that another referendum would be called before any further integration was agreed, in the event, the lack of trust has decided the issue. The people have said "no".
If there is any parallel with the coming UK referendum, it is probably that our contest will be fought on the same battleground. In the Danish referendum, the issues have been complex and technical, especially over whether alternative arrangements for Europol could be agreed.
The people, therefore, have boiled down all the arguments into that one point – whether they trusted their government and legislature to do the right thing on the EU. In the end, the British people may be making the same assessment. And, if the prevailing anti-politician sentiment survives, we might be seeing the same result.