David Cameron has been told his demands to stem the flow of EU migrants to the UK as part of EU reform are "highly problematic" - just hours after setting out his objectives.
The European Commission, the EU's unelected executive body, said the Prime Minister's plan to ban EU migrants from claiming benefits for the first four years counted as "direct discrimination between EU citizens".
In a statement following a speech by the Prime Minister in London, in which he set out four key issues in renegotiating Britain's deal with the EU, the commission said the measures "touch upon the fundamental freedoms of the internal market".
:: What Do PM's Four Objectives Really Mean?
Mr Cameron set out his objectives in a six-page letter to the European Council President Donald Tusk and told him: "I am ready to campaign with all my heart and soul to keep Britain inside a reformed European Union" if an agreement can be reached.
However, the warning from the European Commission, which is headed by President Jean-Claude Juncker, came within hours.
Mr Cameron promised in his speech to end the draw that Britain's generous welfare system has on European migrants as part of his objective to tackle the abuses of the right to free movement.
He said 40% of EU migrants to Britain were helped by benefits, with the average claim of £6,000 per family.
:: David Cameron's Letter To Donald Tusk: In Full
He said he would deliver Conservative manifesto pledges to curb the number of European citizens coming to Europe by welfare reform but appeared to row back on plans to ban EU migrants from claiming in-work benefits for the first four years.
The Prime Minister indicated instead that he was open to other suggestions on how to deal with the immigration issue.
:: PM Heckled By Anti-EU Teen Protesters
He said: "Now, I understand how difficult some of these welfare issues are for other member states and I am open to different ways of dealing with this issue.
"But we do need to secure arrangements that deliver on the objective set out in the Conservative Party manifesto to control migration from the European Union."
It is the challenge to freedom of movement which is the most controversial, since other EU leaders, including Germany's Angela Merkel, regard it as breaching the EU principle of free movement of labour.
However, Ms Merkel said that she was confident that a solution could be found with Britain on its EU membership.
The German Chancellor said she had spoken with Mr Cameron on the telephone on Monday and said she was not suprised by the contents of his letter.
Mrs Merkel added: "There are some difficult points, and some less difficult points. But if one has a spirit of wanting to solve this then I have a certain confidence that this can work out."
Mr Cameron's other three objectives were for: the single market to be protected for Britain and countries outside the eurozone, greater competitiveness in the EU and a "legally binding" exemption for Britain from "ever closer union".
He ruled out a second referendum on Britain's membership of the EU and warned those pushing for an exit from the union: "This choice cannot be undone."
:: Should Britain Stay Or Go?
He said leaving would be a "final decision", with no further renegotiations.
European counterparts were warned that it was "our only chance to get this right - for Britain and for the whole European Union".
And he hinted that if he did not achieve his four objectives from EU leaders he could be prepared to campaign for Britain to leave the union.
:: Top 10 EU Myths Debunked
Mr Cameron would not be drawn on a date for the referendum. There has been speculation it could come as early as summer.
Between now and a December summit, Mr Cameron will hold more talks with European leaders, starting at a migration summit in Malta the day after his speech.
Hardline Tory eurosceptics and campaigners for a so-called "Brexit" claim some of Mr Cameron's objectives are feeble and others stand no chance of success.
UKIP leader Nigel Farage said it was "clear that Mr Cameron is not aiming for any substantial renegotiation".
He said: "His speech was an attempt to portray a new 'third way' relationship with Brussels that is simply not on offer."
Scottish National Party European affairs spokesman Stephen Gethins said: "It is becoming increasingly clear that David Cameron is struggling to get the deal he needs to placate his party's Eurosceptics."