A guide to plans for the UK to leave the European Union, after the 2016 referendum.Read more
It's been more than 12 hours since Theresa May boarded a flight to Brussels to put her seal on an agreement that she hopes will give the Brexit process a huge push forward to its next stage.
Let's recap on the main developments.
Theresa May is expected to brief MPs on the agreement in the Commons on Monday. In the meantime, follow the BBC for reaction to this breakthrough moment over the weekend.
BBC Ireland correspondent Chris Buckler says the skillful drafting of the Brexit document has left all sides claiming victory.
But have some of the key questions about the Irish border merely been "kicked down the road"?
Britain will be able to carry out criminal record checks, should it wish, on EU nationals seeking to stay in the country after Brexit.
The government has said it wants applicants for settled status to have to declare any criminal convictions and for the authorities to be able to check UK databases and, in certain cases, verify international records.
The UK's position was initially met with resistance in Brussels but ministers believe that they have got their way over the issue in Friday's agreement.
The document, released earlier, says: "Systematic criminality and security checks can - in the specific context of acquiring status under the Withdrawal Agreement - be carried out on all applicants for status under the agreement and applicants can be asked to declare criminality."
There's been a bit of a kerfuffle about that picture of Boris Johnson visiting Downing Street yesterday, which was tweeted by chief whip Julian Smith.
He said it was taken "last night" but some eagle-eyed observers spotted the clock on the No 10 mantelpiece, which indicated that it was actually the middle of the afternoon.
It has now been confirmed that the shot was taken at 16.30 GMT.
Does all this really matter? In the scheme of things probably not.
But given Tory fault-lines over Brexit and the feverish atmosphere in the party, the extent of the foreign secretary's involvement in the negotiations and at what stage he was briefed is fascinating to the kremlinologists.
BBC Radio 5 live
Former Irish prime minister Bertie Ahern has told the BBC that Theresa May has been negotiating in good faith and that the government in Dublin has clearly received new guarantees from Downing Street when it comes to the border.
They recognise that she's given very firm guarantees and I think this certainly allows the negotiations to go on. But, you know, we could be still here this time next year arguing about some of the detail."
BBC News Channel
It's fair to say Conservative MP Anna Soubry has not been one of Theresa May's greatest cheerleaders in the past, having called for her to go after June's general election result.
But she is positively gushing in her praise of the PM today, saying she has shown strong leadership and "put her mark" on the first-phase agreement.
She has stood up and she has not been found to be wanting at all."
Remember... the European Parliament has to give its backing to the final deal. Its Brexit coordinator, Guy Verhofstadt, seems to have set some conditions before the parliament will give its blessing to the proposals for citizens' rights.
The 3 million, which lobbies on behalf of citizens from other EU countries living in the UK, says Friday's agreement is a "flawed compromise".
While welcoming some concessions, its chair Nicolas Hatton says too many guarantees are time-limited and many people who have made the UK their home are still "in the dark" about whether they will qualify for settled status.
"Our rights should not have an expiry date," he says. "More worryingly, there is still no clarity around the registration criteria for these rights."
BBC News, Geneva
During his trip to Geneva for a UN debate on human rights, Jeremy Corbyn was asked several times whether Labour thought staying in the single market and the customs union was the best or most realistic option for Britain.
He said he had made it "very clear that we are leaving the EU" and that Labour's policy was tariff-free trade. "Lots of jobs depend on it…it is essential that we maintain and defend those jobs".
However he would not specify how Labour thought tariff-free access could be achieved.
He dismissed Nicola Sturgeon's call for Labour to join forces with the SNP to campaign for a Brexit which involved remaining inside the single market and the customs union, saying that staying in was "not a necessary scenario", adding "we will be making our own case, she can make hers".
Sinn Fein has given a "cautious and qualified" welcome to the agreement on the Irish border although party president Gerry Adams said it was a "work in progress" and many questions remained to be answered.
The devil remained in the detail, he said, and the Irish government must "remain vigilant" as talks progressed to the next stage.
While the communique recognises the unique and special circumstances surrounding the issue of the Irish peace process and the border, it does not address key areas of concern for many citizens - especially nationalists living in the north and citizens in the border region. The insistence by the British that Britain and the north must leave the customs union and the single market presents a real and live danger which cannot be understated."
This is a few hours old but we think it is worth sharing even now.
The UK's top civil servant, Sir Jeremy Heywood, earlier described Friday's first-phase agreement as a "vital milestone" in the Brexit process.
Conservative Chief Whip Julian Smith has posted a picture of the Foreign Secretary speaking to Theresa May at Number 10 last night.
Mr Smith says Boris Johnson was there for a "quick update" on the Brexit talks, which lasted most of the night, as did the Downing Street Christmas party, coincidentally.
Was Mr Johnson multitasking?
Reading the joint report between the UK and the EU, it is clear that the most important section when considering the economics of Brexit is the section on Ireland.
The document commits both sides to an open border between Northern Ireland and the Republic, and that there will be "no new regulatory barriers" between Northern Ireland and the rest of the UK.
It also commits to the UK leaving the EU's single market and customs union.
These two positions appear to be in contradiction.
If Britain does become a "third country" - that is trading with the EU as other non-EU countries outside the single market and the customs union do - then border controls will be necessary.
And that open border will become very much more closed. There is at least a partial way around this conundrum. Read more from Kamal
Labour leader Jeremy Corbyn has been speaking about Friday's Brexit agreement during a visit to the United Nations in Geneva.
Asked if he thought it represented a significant breakthrough, he said "no" and suggested he wanted more clarity on how long the UK will stay in the customs union as well as protection for workers, consumer and environmental rights.
Many of Friday's details, including the residency guarantee for EU citizens, could have been settled almost nearly 18 months ago, he suggests.
"This could have been done some time ago...The referendum took place in 2016. This is the first sign of movement since then."
Labour, he says, wants long-term tariff-free access to EU markets for British businesses.
"It is essential we protect and defends these jobs," he adds.
Most Brexit-suppporting Tories seem to be happy about what's been agreed although some are picking the odd hole in the documents.
Former Welsh Secretary David Jones is worried about the implications if there is no agreement on how cross-border trade in Ireland is regulated.
In such a scenario, he tells Radio 4's World at One the UK will be fully aligned to existing EU single market rules relating to North-South co-operation - a situation he thinks would hamper efforts to strike trade deals with other countries after the UK leaves.
The worry about that is of course that it could relate to very important areas such as, for example, agriculture which we would want to throw into the mix in negotiating a free trade agreement with a third country. And if this was to persist it could severely handicap our ability to enter into those free trade agreements so I think we do need to see that particular provision refined."
Are you one of the three million or so citizens of other EU countries currently living in the UK worried about their future?
In summary, EU and UK citizens will have free movement of rights until the day the UK withdraws from the EU - 29 March 2019.
This, in effect, is the cut-off date for EU citizens moving to the UK. Anyone who arrives before Brexit day will have the right to stay.
Those who are yet to be granted permanent residency in the UK will have their rights protected, so they can still acquire it after withdrawal.
The latest deal also includes reunification rights for relatives who do not live in the UK, to join them in the future.
The Democratic Unionists say the deal struck by Theresa May to advance the Brexit talks shows they are playing a pivotal role in the process.
DUP MP Nigel Dodds told BBC Radio's 4 World at One programme: "I think the events of this week tells us a lot about our power.
"We stopped something that wasn't in the interests of Northern Ireland and the prime minister herself has indicated that the deal today is significantly improved."
And here's how Mr Dodds summed up the deal in an earlier tweet.
Brexit minister Steve Baker says ex-UKIP leader Nigel Farage is "not very well informed" in his claim that the final Brexit divorce bill could be as high as £60bn.
He tells BBC Radio 4's World at One the UK will honour its budgetary obligations and, on the basis of publicly available data and other policy assumptions, the final figure will be at the "lower end" of the £35-£39bn range.
Asked about claims that the calculations could increase, he says ministers are "not expecting that".
More broadly, he says Friday's phase-one agreement has been welcomed by business and Tory MPs are in a "happy place".
"There is much to celebrate," he adds.
Former Chancellor George Osborne says those who advocate a "softer Brexit" will celebrate the deal struck by the prime minister to advance the talks on the UK's withdrawal.
Mr Osborne, editor of the Evening Standard newspaper, says the agreement "points to the shape of things to come."
He makes the comments in an introduction to an editorial in this evening's edition.
Daily Politics presenter
Spanish citizen Olga Garcia reacts to the Brexit agreement to protect EU immigrants living in the UK.
Home Secretary Amber Rudd, one of the leading proponents of a "soft Brexit" within the cabinet, has welcomed the agreement.
Speaking during a visit to the National Fraud and Cyber Crime reporting centre, she said.
I am delighted we have got through phase one. There is going to be more to do but it shows under Theresa May's leadership we are able to have successful negotiations and take forward this really important step of negotiating our exit from the EU."
A few months ago, the EU released an incredibly detailed and complicated document which sought to explain the state of talks on citizens' rights.
The "technical note" colour-coded key areas based on the level of progress, with green marking agreement, amber marking a degree of consensus and red signalling disagreement or lack of discussion.
An updated version published on Friday has gone completely green.
Former Tory Attorney General Dominic Grieve says he is happy with the section of the Brexit agreement relating to the European Court of Justice.
He says would be "fanciful" to deny the ECJ any role in the UK after Brexit, particularly with regard to the enforcement of the rights of EU citizens remaining in the country.
But he thinks it would be "extremely unusual" for British judges to decide to refer cases to the Luxembourg-based court.
Ultimately if we are embedded in a European system where we are trading, then it is going to be a court which has some influence over our affairs. I don't see this proposal in any way undermining our national sovereignty. It makes perfect sense."
The world through its media
The Scottish Conservative leader says Friday's developments are a "real step forward".
Ruth Davidson added: "Throughout this process, my overriding priority has been to ensure we act as one United Kingdom and no home nation is left behind.
"I am therefore glad that this morning's agreement ensures the integrity of the UK."
The MSP said it was now time to begin working on a "comprehensive trade agreement", which would require "more hard work and patience".
Guidelines setting out the EU's proposed future relationship with the UK after Brexit have been leaked.
They say the UK will remain a “member” of the EU’s customs union and single market during any transition period, likely to last about two years.
They also suggest the UK will remain under the full jurisdiction of the European Court of Justice for a number of years after the March 2019 exit.
Membership of the single market means keeping all of the EU’s “four freedoms” – goods, services, capital, and labour – although the UK government says that new long-term arrivals from the EU (not tourists) will have to register during the transition period.
Membership of the customs union restricts the UK’s ability to sign new trade deals but informal negotiations with other countries could still be possible.
If this is confirmed, it is likely to delight supporters of a soft Brexit, who want a virtual "status quo" during a transitional phase, but will undoubtedly alarm those Brexiteers who want a clean break with the EU.
More clarity on the Brexit transition is needed to stop companies proceeding with contingency plans despite the progress announced on Friday, the CBI has warned.
Paul Drechsler, president of the business lobby group, said companies had begun triggering plans months ago.
However, more detail could help suspend further action by firms, he said.
Put simply, the deal states a broad agreement on principles rather than a specific figure.
However, what we do know is the UK's financial settlement will be paid in euros and that Britain will not fund anything that the other member states do not.
In the joint report, the UK's obligations are set out with some calculations yet to be made.
So can we plan for it? Yes but the schedule of payments is still to be decided.
Nigel Farage is on the Victoria Derbyshire show and he is not happy.
The former UKIP leader says the UK's potential divorce bill is "gargantuan" and "way more than we need to pay", suggesting the UK "looks like mugs".
The continuing involvement of the European Court of Justice for up to eight years is not what Leave backers voted for in June 2016, he adds.
The whole thing is humiliating. We have collapsed at every level...Everything that has been agreed today is against what 17.4 million people voted for on 23 June 2016."
The TUC says unions and employers need to be closely involved in the next phase of talks on the UK's relationship with the EU after Brexit.
While welcoming Friday's progress, general secretary Frances O’Grady says Theresa May should reconsider her decision to leave the single market and customs union which she says is "getting in the way".
The government must drop its self-defeating red lines and put these options back on the table. And before the next round of talks, we need a sea-change in the way government acts. Ministers need to bring in the negotiating expertise of unions and employers."