The EU has agreed to give the UK a Brexit extension until 31st January.
However, the UK will be able to leave earlier - either at the start of December or January - if the withdrawal agreement is approved by the British parliament.
EU ambassadors met in Brussels this morning to consider a text on the UK's request for an extension until January.
In a tweet, European Council President Donald Tusk confirmed a 'flextension' had been agreed.
The EU27 has agreed that it will accept the UK's request for a #Brexit flextension until 31 January 2020. The decision is expected to be formalised through a written procedure.
— Charles Michel (@eucopresident) October 28, 2019
The UK had been scheduled to leave the bloc on 31st October - only a few days from now.
However, Boris Johnson was forced to seek an extension after MPs in Westminster refused to sign off on his new Brexit deal before that legal deadline.
Meanwhile, MPs are today due to debate Boris Johnson's proposal for an early general election on 12th December.
He says that's a condition for giving MPs more time to debate the Brexit deal legislation.
However, he needs a two-thirds majority to approve an election - which he does not have.
The SNP and Liberal Democrats are instead set to push for an election on 9th December - and are also working to make sure Mr Johnson would not be able to pass the Brexit deal ahead of the vote.