Marks & Spencer is poised to receive a substantial VAT refund over a 13-and-a-half year legal battle over chocolate teacakes.

The European Court of Justice (ECJ) has ruled that the retail giant is entitled to a£3.5 million VAT refund from HM Revenue & Customs because the dome-shaped teacakes are chocolate cakes and not biscuits, according to The Daily Telegraph.

However, HMRC is not prepared to concede just yet: it wants to hear whether the House of Lords accepts the ECJ decision, but tax experts believe M&S is “home and dry”, the newspaper reported.

The origins of the M&S case go back to the introduction of VAT in 1973, when the M&S teacakes were classified as biscuits and subject to standard-rate VAT.

21 years later, the then-Customs & Excise admitted a mistake and agreed that the teacakes were, in fact, chocolate cakes, which are zero-rated for VAT purposes.

In its judgement yesterday, the ECJ ruled that there should be no difference in treatment between EU governments and taxpayers in case of reimbursement for tax errors, one of the key points in question.

M&S told The Daily Telegraph it was pleased with the judgement and optimistic that the House of Lords would “draw a line under this protracted litigation”.