More than a decade after the collapse of Lehman Brothers sparked the global financial crisis, the British taxman may be in line for a £1bn windfall.

The UK supreme court ruled on Wednesday that administrators overseeing the winding up of the investment bank must pay tax on more than £5bn in assets that have been left over from the collapse.

A standard tax rate of 20% translates to more than £1bn for HM Revenue and Customs (HMRC) coffers.

An HMRC spokesperson said: “We welcome the supreme court ruling that confirms our analysis and means over £5bn is in scope of withholding tax rules. This is another example of HMRC seeking robust challenges to ensure that money is available for the UK’s vital public services.”

Lehman Brothers, an emblem of the Wall Street investment banking boom, went bankrupt on 14 September 2008 when it ran out of cash to pay its bills after banks stopped lending money to each other. The subsequent panic sparked the worst global recession since before the second world war.

However, while Lehman Brothers was insolvent in cash terms, its balance sheet still held valuable assets. As the panic subsided, the value of those assets recovered as well, leaving a surplus of £7bn after paying former Lehman employees, creditors and suppliers what they were owed. In total, administrators have recovered more than £40bn from Lehman.

The administration has been particularly profitable for hedge funds, including King Street Capital Management, Elliott Advisors and CarVal Investors. They bought debt owed by Lehman to other parties at the height of the crisis at bargain prices.

Some of the debt was bought for prices of about 20p for every pound of face value. With creditors expected to receive about 140p for every pound of debt, the boldest of the investors have made staggering profits from the administration.

Fees for the decade of work in winding up the bank, including by the administrators PwC and legal advice from the likes of Linklaters, have reached almost £1bn as well.

Sign up to the daily Business Today email or follow Guardian Business on Twitter at @BusinessDesk

About £5bn of the surplus took the form of statutory interest, sparking a legal battle between administrators and HMRC over whether or not they were liable for tax. HMRC successfully appealed against an initial high court ruling in favour of the administrators.

The supreme court described the surplus from the administration as “unprecedented”. In the judgment, Lord Briggs, one of the 12 judges who serve on Britain’s highest court, wrote: “It is no mere irony that [Lehman Brothers’] unsecured debt has, during that last 10 years, turned out to be a very satisfactory long-term investment.”

More than 3,500 UK bankers paid €1m a year, says EU report Read more

However, the money is not quite secure for HMRC. Some of the hedge fund creditors are understood to have launched claims to stop the payments to HMRC under treaties designed to prevent income from being taxed in two countries.

Russell Downs, a partner for PwC who led the Lehman administration, said: “We are pleased that the supreme court has handed down this important decision on a technical tax issue. It provides the clarification needed in the rare circumstances where insolvency officeholders pay interest to creditors out of an estate’s surplus – having paid creditors in full – as has been achieved in the case of LBIE [Lehman Brothers International Europe], and other UK Lehman companies, by PwC.”