Image copyright PA Image caption Sir Keir has been shadow Brexit secretary since last year

Labour would keep the UK in the EU single market and customs union for a transitional period after leaving the EU, the party has said.

Shadow Brexit secretary Sir Keir Starmer set out Labour's new position in the Observer.

The shift in policy would mean accepting the free movement of labour after leaving the EU in March 2019.

Sir Keir said the transition would be "as short as possible but as long as necessary".

Meanwhile, Brexit Secretary David Davis has urged the European Commission to have a flexible approach to talks.

Labour's leadership has been criticised by opponents for a lack of clarity on what deal Britain should seek immediately after leaving the EU.

Sir Keir said a transitional period was needed to avoid a "cliff edge" for the economy, so that goods and services could continue to flow between the EU and UK while negotiations on the permanent deal continued.

"Labour would seek a transitional deal that maintains the same basic terms that we currently enjoy with the EU," he wrote.

"That means we would seek to remain in a customs union with the EU and within the single market during this period.

"It means we would abide by the common rules of both."

He compared this with the government's preference for "bespoke" transitional arrangements after leaving the EU, which, Sir Keir said, were highly unlikely to be negotiated before March 2019.

He did not say how long the transitional period would be - only that it would be "as short as possible, but as long as is necessary".

Analysis

Image copyright Getty Images Image caption Jeremy Corbyn's office confirmed the proposals had been agreed with him and were official policy

By BBC political correspondent Jonathan Blake

A significant shift or simply the clarification of a confused picture?

Either way, Labour's plan for a transitional period after the UK leaves the EU only takes us so far.

Yes, we now know that a Labour government would keep the UK in the customs union and single market for some time after March 2019.

But how long for? And what happens after that?

Sir Keir has suggested continued membership of the customs union and single market with stricter controls on immigration.

That idea is likely to go down about as well as a flat beer in Brussels.

In the words of the EU's chief negotiator, "cherry picking is not an option".

Labour's plan will be music to the ears of its remain-voting supporters in London and beyond.

But to those in the party's heartlands, keen to see the back of Brussels, it may sound more like an alarm bell.

The customs union is the EU's tariff-free trading area, which imposes the same taxes on imports from certain countries outside the union.

The single market also includes the free movement of goods, services, capital and people.

"Those who campaigned to leave the EU are likely to be concerned that this could see unlimited migration continue for some time after Brexit," said the BBC's political correspondent Iain Watson.

After the transitional period, Sir Keir said, the new relationship with the EU would "retain the benefits of the customs union and the single market", but how that would be achieved "is secondary to the outcome".

Remaining in a form of customs union with the EU was a "possible end destination" for Labour, he said, but that must be "subject to negotiations".

He said a final deal must address the "need for more effective management of migration".

Jeremy Corbyn's office confirmed that the proposals had been agreed with him and were official policy.

TUC general secretary Frances O'Grady said it was a "sensible and reasonable" approach to take, and would give working people "certainty" on their jobs and rights at work.

Labour MP Chuka Umunna, co-chairman of the all-party parliamentary group on EU relations, told BBC News the change in policy was "welcome" and urged Labour to commit to staying in the single market after the transition period.

However, a spokesman for Labour Leave, a pro-Brexit movement, warned the party risked losing the 37% of Labour voters who voted to leave the EU.

"Seven out of 10 Labour constituencies voted Leave. Single market membership is EU membership in all but name. Labour must honour the referendum," it tweeted.

Get news from the BBC in your inbox, each weekday morning

Liberal Democrat Brexit spokesman Tom Brake said it was "all spin and no principle".

Meanwhile, the SNP's Westminster leader, Ian Blackford, said Labour was simply delaying the UK's departure from the market, saying: "Labour still face a cliff edge, only later than the Tories."

Former-UKIP leader Nigel Farage tweeted that Mr Corbyn had "betrayed every Labour voter", having said he would support the UK leaving the single market during the general election campaign.

'Temporary customs union'

The government has also called for a transition period to help business adjust after Brexit.

But chancellor Philip Hammond and trade secretary Liam Fox said the UK would be "outside the single market and outside the customs union" during this period.

A paper subsequently published by the government said it could ask Brussels to establish a "temporary customs union" after March 2019.

But during this period, it would also expect to be able to negotiate its own international trade deals - something it cannot do as an EU customs union member.

Meanwhile, Brexit Secretary David Davis will meet the European Commission's chief negotiator Michel Barnier on Monday to formally open Brexit discussions.

The government said this week's negotiations were "likely to be technical in nature", ahead of more substantial talks in September.

It said both sides must be "flexible and willing to compromise" when it comes to solving areas where they disagree.