David Cameron has set up a new unit in Whitehall to come up with options for how Brexit will actually work – after officials failed to make contingency plans in advance.
The team of civil servants will be based in the Cabinet Office and will present its findings to the new prime minister in the autumn.
Cabinet minister Oliver Letwin will play a "facilitative" role hearing from people from within and outside government about what the next steps should be.
Cameron's spokeswoman said the new unit had been approved at a special cabinet meeting on Monday, as ministers met to discuss the fallout of Britain voting to leave the European Union last week.
She said: "The point of this team is that the British people have decided to leave the European Union. The civil service, as we were clear in the run-up, had not done contingency work on what that would be.
"Now we can start the work, mandated by the prime minister and this government, to put the UK in the best possible positions for those negotiations and for our future relationship with the European Union."
The new team – comprising officials from the Treasury, Foreign Office, and Cabinet Office – will "lead intensive civil service work on the issues that will need to be worked through", she added.
They will present their options and advice to a new prime minister and cabinet once Cameron's successor is appointed in September.
"It's the pre-thinking, it's not the decision-making because it's right that that decision is taken by the new prime minister and the new government," the spokeswoman said.
"It's also not just about options for the negotiation. If you think about it, this is going to be a very complex task. What are the transitional arrangements – what happens between now and the point at which the UK leaves? How are those negotiations conducted? What form does the UK's relationship take with the European Union afterwards?"
In a statement to MPs later on Monday, Cameron said the unit would carry out the "most complex and most important task that the British civil service has undertaken in decades".
He said it would be "staffed by the best and brightest from across our civil service", adding: "It will report to the whole of the cabinet on delivering the outcome of the referendum, advising on transitional issues and exploring objectively options for our future relationship with Europe and the rest of the world from outside the EU.
"And it will be responsible for ensuring that the new prime minister has the best possible advice from the moment of their arrival."
Emily Ashton is a senior political correspondent for BuzzFeed News and is based in London.
Contact Emily Ashton at firstname.lastname@example.org.
Got a confidential tip? Submit it here.