Britain has been told it must pay an extra €2.1bn (£1.7bn) into the European Union budget by the end of next month because the UK economy is doing better relative to other European economies.

The demand is certain to be used against David Cameron by the growing camp who want the UK to quit the EU.

British and European commission officials confirmed that the Treasury had been told last week that budget contribution calculations based on gross national income (GNI) adjustments carried out by Eurostat, the EU statistics agency, had exposed a huge discrepancy between what Britain had been asked to contribute and what it should be paying, because of the UK’s recovery.

The bombshell, first reported by the Financial Times, was dropped into the middle of an EU summit in Brussels where Cameron and 27 other leaders were mired in tough negotiations over climate-change policy and attempts to agree big reductions in greenhouse gas emissions by 2030.

A Downing Street source said: “It’s not acceptable to just change the fees for previous years and demand them back at a moment’s notice. The European commission was not expecting this money and does not need this money and we will work with other countries similarly affected to do all we can to challenge this.”

The prime minister on Thursday evening conferred with Mark Rutte, the Dutch prime minister, as the Netherlands has also been ordered to pay more than €600m extra into the budget, while other countries such as Germany and France are likely to have excess contributions returned.

The commission told the various countries of the revamped figures on 17 October, EU officials said. They said the British had until 1 December to provide €2.1bn, roughly a fifth of the UK’s annual net contribution to the EU.

The demand for the money is political dynamite for a prime minister wrestling with dilemmas over Britain’s future in Europe and broadly seen to be making increasingly Eurosceptic gestures to the restless backbenchers who want to deal with Nigel Farage’s Europe rejectionists.

“The timing is far from ideal,” said Patrizio Fiorilli, spokesman for the EU budget commissioner. “But there are rules we have to follow.”

“It’s crazy,” said Richard Corbett, a Labour MEP and former senior EU official. “This must be an automatic thing because politically the timing could not be worse.”

Farage, leader of Ukip, led the condemnation of the European commission plan. “Having come to Britain to set fire to David Cameron’s migration ideas, José Manuel Barroso [European commission president] has returned to Brussels to pour more fuel on the flames,” he told the Guardian.

“This is the EU making clear that economic success is not to be applauded but to be punished. Mr Cameron has to veto this if he is to have any credibility at all.”

Leading Tories also condemned the commission. MP Tracey Crouch, who is playing a key role in the campaign for the upcoming Rochester and Strood byelection, said: “You should not punish countries that are working hard to recover from the great recession. The EU should look at George Osborne’s long-term economic plan and learn some lessons from it.”

Nick de Bois, a senior member of the Tory 1922 backbenchers’ committee, said: “Only the EU would demand more money when everyone is belt-tightening. Only the EU would want to penalise growing economies to subsidise those that have not made the tough decisions. There is only one answer to such a ludicrous demand – no.”

Mark Pritchard, former secretary of the 1922 committee, said: “Penalising the UK for its economic success goes to the very heart of what is wrong with Europe. It is Europe’s waste and inefficiencies that should be targeted by Brussels – not UK taxpayers. We pay enough already. Not a single euro more should be paid.”

The request for the money comes as Cameron and his party, under pressure from Ukip to bolster their anti-EU credentials, are embroiled in fights with Brussels and other EU capitals over freedom of movement and immigration within the EU, and over Cameron’s insistence on rewriting the terms of Britain’s EU membership before putting a new deal to an in-out referendum by 2017 if he wins a second term next year.

Cameron has set great store on campaigning to reduce the overall EU budget, arguing that at a time of austerity and spending cuts all across Europe, the Brussels pot could not remain immune.

Eurostat arrived at the €2.1bn figure on the basis of new methods of calculating member states’ GNI since 1995, taking account of previously unreported or under-reported black economy elements, such as drug dealing and consumption or the sex industry.

Eurostat concluded that the UK economy has been doing much better than previously assumed since 1995, relative to other European countries, and that British contributions needed to be upped.

“It changes the way contributions to the budget are calculated,” said Fiorilli. “Some member states have booming economies. Everyone can see the UK is growing much faster than others.”

Fiorilli said that the commission and Eurostat use 1995 as the benchmark year for calculating the impact of GNI figures. “Member states including Britain insisted on this. It is their decision,” he said.

The demand comes as part of what is known in Brussels as an amending budget proposal, a routine event that occurs regularly and is dependent on the ebb and flow of payments into the EU machine. There are currently a further six amending budgets on the table in Brussels, some of which may entail returning funds to Britain, meaning the overall bill could yet be cut.

While the €2.1bn bill is theoretically due by 1 December, the amending budget also has to be endorsed by the 28 governments of the EU and by the European parliament, meaning it could run into resistance if Britain is able to marshal enough allies and given that there are many European governments reluctant to hand an easy victory to those campaigning to take the UK out of the EU.