European commission president, Jean-Claude Juncker, made the announcement at a press conference with Theresa May early on Friday after the British prime minister and David Davis travelled to Brussels for last-minute talks.

May said that the deal would ensure “no hard border” in Ireland and added that the deal was a “significant improvement” which had required give and take on both sides. Juncker said that negotiations had been “difficult” for the EU and the UK.

Earlier, DUP leader Arlene Foster had said her party had won “six substantive changes” to the text on the Irish border in overnight talks, ensuring there would be “no red line down the Irish Sea”.

On a morning of drama in Brussels, May was met by Juncker and his chief of staff, Martin Selmayr, shortly before 7am local time. Their meeting follows a flurry of diplomacy by May late on Thursday that fuelled speculation an agreement was edging closer.

Expectations that an announcement was imminent hardened when Selmayr tweeted a picture of white smoke emerging from the Vatican, the Catholic Church’s signal that a new pope has been chosen.

After a week of false starts and frustration, with the DUP refusing to sanction a previous form of words on regulatory alignment between the UK and the EU, May had been warned that she only had until midnight on Sunday to salvage the agreement or face a long delay in starting Brexit trade talks.