The EU has issued an ultimatum asking Britain to pay £20 million for customs duty on garlic.
The British government could face legal action if the amount is not paid within two months.
The EU has charged the UK government for violating EU norms by levying a lower rate applicable to frozen garlic on imports of the fresh product from China.
"Between 2005 and 2006, the UK customs authorities allowed imports of fresh garlic from China under wrong authorising documents. They have erroneously stated that the goods imported were frozen garlic for which significantly lower import duties apply," the EU said in a statement.
"The European Commission considers that the UK authorities did not act with all due care when issuing the authorising documents and failed to collect the correct amount of duties. They are therefore held financially responsible for the loss of approximately £20 million to the EU budget."
According to the EU guidelines, all customs duties charged on imports of goods coming from a non-EU country are collected by member states on behalf of the EU and paid to the common EU budget as part of each member state's annual contributions. One quarter of the total raised amount from such duties is retained by the national government to cover collection costs.
This form of contribution to EU funds makes up about 12 percent of the total annual sum submitted by the 27 EU members.
The error was detected during an inspection from OLAF, the EU's anti-fraud unit, in July 2006.