WASHINGTON: US President Barack Obama has urged Britain to stay in the European Union, cautioning remaining in the bloc was necessary to help preserve the nation’s global influence.

Obama’s comments, during an interview with the BBC aired on Thursday, come ahead of a planned British referendum that will determine whether the country remains in the EU.

“Having the UK in the European Union gives us much greater confidence about the strength of the transatlantic union,” Obama said. “We want to make sure that the United Kingdom continues to have that influence.”

Obama went on to refer to the EU as a “cornerstone of institutions built after Second World War” that has helped make the global community “safer and more prosperous”.

Conservative British Prime Minister David Cameron has promised to hold a referendum on the country’s EU membership by the end of 2017.

The vote, which is going ahead after Cameron’s centre-right Conservatives won a clear majority during general election held in May, is scheduled to take place sometime before 2017 but could come as early as next year.

Cameron is negotiating with European Union leaders to try to change the terms of Britain’s membership of the bloc before holding the referendum.

Last month, Cameron told reporters at the G7 summit in Germany his goal was to “renegotiate, get a deal that’s in Britain’s interest and then recommend Britain stays in it”.

The EU has been rocked in recent weeks by contentious negotiations between Greece and international creditors to secure a third bailout for the nation and prevent the country from exiting the union.