Intervention from senior US official comes as UK position on EU membership is criticised in Brussels and Dublin

The Obama administration issued a direct challenge to David Cameron over Europe, on Wednesday when it warned of the dangers of holding a referendum on Britain's membership of the EU.

A senior US official questioned the merits of holding a referendum as the prime minister's campaign to reset the terms of Britain's EU membership also came under assault from Brussels and Dublin.

With just weeks to go until Cameron delivers a landmark speech in which he is expected to promise to hold a referendum on a "new settlement" for Britain in the EU, the US assistant secretary for European affairs warned that "referendums have often turned countries inwards".

"We welcome an outward-looking European Union with Britain in it. We benefit when the EU is unified, speaking with a single voice, and focused on our shared interests around the world and in Europe," Philip Gordon said during a visit to London, adding: "We want to see a strong British voice in that European Union. That is in the American interest."

Gordon stressed that it was it was up to Britain to determine its European role but, in what appeared to be a clear reference to attempts to renegotiate UK membership with the EU, he said: "It would be fair to say that every hour at an EU summit spent debating the institutional makeup of the European Union is one less hour spent talking about how we can solve our common challenges of jobs, growth, and international peace around the world."

The intervention by Gordon, who was in London to meet the Europe minister, David Lidington, highlights the alarm in Washington as opinion polls show a rise in support for British withdrawal from the EU and the prime minister prepares to set out how he will repatriate powers from the EU.

Cameron is expected to say in his speech that, if elected with a majority in 2015, he will use an EU treaty revision to underpin new eurozone governance arrangements to repatriate some powers.

The new terms of British membership would be put to the UK public in a referendum.

It has been the US position for several years that close British engagement in Europe was in American interests.

But Gordon's remarks appeared to be a clear message to the government that the "special relationship" would be devalued in the eyes of the Obama administration if Britain left the EU, or got bogged down in drawn-out negotiations on the details of its membership.

A Downing Street spokesman said: "The US wants an outward looking EU with Britain in it, and so do we."

The forthright American intervention came as Cameron's plans also came under concerted attack from Brussels and the Irish prime minister, Enda Kenny, whose country holds the six-month rotating presidency of the EU.

At an event in Dublin marking Ireland's assumption of the presidency, Kenny described the prospect of Britain quitting the EU as a "disaster", while Herman Van Rompuy, the president of the European Council, called on the UK to remain an "active, full, and leading" EU member.

Van Rompuy also cast doubt on whether a major revision of the treaty – essential to Cameron's strategy – would actually take place. He said EU states could not agree on what they wanted to change in the treaty, so the prospect of a renegotiation was remote.

"At this stage of the debate we don't need as much treaty change as people think," said Van Rompuy. "For those ideas for where treaty change is needed there is simply no consensus. So the possibility of having treaty changes in the near future or present are not very high."

He said he would wait to hear what Cameron said about Britain in Europe, although there is much confusion in EU capitals about when and where the prime minister will deliver a speech that has been given high billing for some months.

Cameron's stated strategy of securing a looser UK-EU relationship hinges on 27 governments re-opening the Lisbon Treaty, enabling Britain to push changes "repatriating" powers from Brussels.

In fact, the other EU leaders want to avoid treaty change as it could result in years of gruelling negotiations and open a pandora's box of competing claims.

Senior Irish politicians said other European governments were privately urging Cameron to desist. Kenny warned that the EU's "floodgates" would be opened if the Lisbon Treaty was revisited to suit an individual country.

"We would see it as being disastrous were a country like Britain to leave the union. Clearly the British government will form their own view," he said.

Van Rompuy said: "Britain is a highly appreciated, highly valued and very important member of the EU. I believe it is in British interests to stay, not only a member of the EU but a very active and full member, a leading nation in the EU. Of course it is for the British people to decide on their future."