A British court rejected a $2 billion lawsuit brought by Danish tax officials against Dubai hedge fund trader Sanjay Shah.
Mr Shah, a British man living in Dubai, had his assets frozen during the court case brought by Danish tax authority Skat, which claimed he was the key mover in the alleged fraud.
Judge Andrew Baker, sitting at London's High Court, said the UK was not the proper place to bring a foreign tax claim.
"Skat's claims seek indirectly to enforce here Danish revenue law. Such claims are not admissible in this court," he said.
The Danish tax authority, which launched the legal action in the UK – against Mr Shah and 70 other defendants – because it is where many of the companies allegedly involved are based, said it would appeal.
The civil case was only one avenue Denmark was pursuing in an attempt to claw back huge tax rebates it says it unwittingly handed to Mr Shah and others.
Skat claimed Mr Shah was a central player in a scheme in which foreign companies pretended to own shares in Danish companies, then claimed tax refunds for which they were not eligible.
Mr Shah said his schemes were a “widely known and wholly legitimate trading strategy”.
The ruling is a setback for Denmark and its tax agency, which said it “fundamentally disagrees” with the verdict. Skat said it was not a tax claim, but rather a civil claim, where it seeks to have the amount returned.
Mr Shah's lawyer Chris Waters said his client and the other defendants were subjected to “three years of unnecessary litigation in the UK".
“As a consequence, our clients suffered very significant financial loss and damage which they will seek to recover from the Kingdom of Denmark," he said.
Last year, Danish authorities froze many of Mr Shah's assets, including a £15 million ($20.8m) home near Hyde Park in London.
A centre for autistic children in the UAE, funded by Mr Shah, was closed as part of the global asset freeze on his multimillion-pound fortune.
His company, Solo Capital Partners, which closed in 2016, was the main financier of the Autism Rocks Support Centre, charity financial records show.