European Union leaders have granted the UK a six-month extension to Brexit, after five hours of talks in Brussels, reports BBC.
The new deadline - 31 October - averts the prospect of the UK having to leave the EU without a deal on Friday, as MPs are still deadlocked over a deal.
European Council president Donald Tusk said his "message to British friends" was "please do not waste this time".
Theresa May, who had wanted a shorter delay, said the UK would still aim to leave the EU as soon as possible.
The UK must now hold European elections in May, or leave on 1 June without a deal.
The prime minister had earlier told leaders she wanted to move the UK's exit date from this Friday to 30 June, with the option of leaving earlier if her withdrawal agreement was ratified by Parliament.