The border arrangements between Northern Ireland and the Republic of Ireland, which remains in the EU, have been a difficult point, with checkpoints of fears that could damage both economies and undermine the hard-won peace in the North.
Following the evening talks between the conservatives of British Prime Minister Theresa May and her ruling partners, the hard-line Irish Democratic Unionist Party, moved to Brussels on Friday where she met with the President of the European Commission, Jean -Claude Juncker.
Speaking with May in the European capital, Juncker said, "we had to make the deal today," as the December 14 deadline approached.
"There has already been enough progress in the three terms of the divorce," Juncker said, referring to the conditions the EU had requested on a number of issues, including the Irish border. Negotiations for the UK to leave the EU can now move on to the next stage.
"This has not been easy for either side," May said. "Reaching this point has required giving and receiving on both sides."
Referring to a point of friction between his party and the DUP, May said: "In Northern Ireland we will guarantee that there will be no difficult borders, and we will maintain the (Good Friday Agreement)."
"No barrier north-south or east-west," he said.
What was agreed?
When the Brexit negotiations began just over six months ago, the EU was clear on its position: it would not tolerate any discussion of a future relationship with Britain until "sufficient progress" had been achieved on three issues.  These are:
– that the rights of European citizens in the United Kingdom are guaranteed
– that Great Britain pays a substantial "divorce bill"
– and that there is no reinstatement of a border It lasts between Northern Ireland, which will leave the EU with the rest of the United Kingdom, and the Republic of Ireland, which remains in the EU.
"The agreement we have reached will guarantee the rights of more than three million EU citizens living in the UK, and more than one million UK citizens in the EU," May said.
European citizens who remain in the United Kingdom after Brexit will retain social security, medical care and a host of other legal rights, according to the statement.
A framework for a financial settlement was also agreed, including the United Kingdom, which will contribute to the annual EU budgets until 2020.
Question of Northern Ireland
Language on the situation in Ireland was less clear. The statement acknowledges that the withdrawal of the UK from the EU "presents a significant and unique challenge in relation to the island of Ireland" and the need to avoid a difficult border with checkpoints and controls.
"The United Kingdom remains committed to the protection of North-South cooperation and its guarantee of avoiding a hard border," the statement said.
"Any future agreement must be compatible with these general requirements.The intention of the United Kingdom is to achieve these objectives through the EU-UK general relationship.If this is not possible, the UK will propose specific solutions to address the unique circumstances of the island of Ireland ".
Deputy Prime Minister of the Republic of Ireland Simon Coveney said on Twitter that Dublin "supports the Brexit negotiations by moving to Phase 2 now that we have secured guarantees for all on the island of Ireland – fully protecting (the Good Friday agreement ), peace process, economy of the whole island and guarantee that there can not be DIFFICULT FRONTIER ".
The Irish border problem was the last stumbling block in torturous negotiations.
It is a historically sensitive issue: the dismantling of border controls and infrastructure was a key piece of the Good Friday Agreement, which brought peace to Northern Ireland after years of sectarian conflict.
While London, Dublin and Brussels seemed to be in favor of Northern Ireland remaining subject to the main European regulations and laws, avoiding the need for border controls, coalition partners in May were not having it.
It is not clear what kind of agreement could have been reached with the DUP, but although the May government depends on them to stay in power, the Northern Irish party could also lose a lot if the unstable coalition collapses.  The DUP secured a financing agreement of £ 1.5 billion ($ 2 billion) for Northern Ireland when it agreed to support May, and the government's failure would likely trigger an election that could well lead Jeremy Corbyn's Labor Party to power, who will not be so sympathetic to the right-wing DUP.
CNN journalist Marilia Brocchetto and James Masters contributed.