After more than 24 hours of talks that went through the night, into breakfast, then lunch and finally dinner - at 11pm last night David Cameron emerged, a little bleary eyed, in front of the cameras to announce he had a deal that would allow him to campaign “heart and soul” for Britain to remain in the European Union.
But how good was the deal Cameron struck with other EU leaders? Did he get what he asked for and will it make any difference to life in Britain?
What he wanted: A key demand of the Prime Minister going into the negotiations was that Britain should be excluded from the declaration in EU treaties that commits member states to “ever closer union among the peoples of Europe”.
Did he get it? Yes. The language in the agreement is emphatic. "It is recognised that the United Kingdom is not committed to further political integration in the European Union," it says. "References to ever-closer union do not apply to the United Kingdom." In particular Cameron won confirmation from other EU leaders that this 'special status' will be enshrined in the next EU treaties – accepting once and for all the reality of a two speed European Union.
Win rating 5/5
What he wanted: Going into the original negotiations David Cameron wanted Britain to able to impose a ban on paying in-work benefits to any EU migrant coming to the UK. He also put forward a plan that would allow the UK to stop paying child benefit to the children of migrants who were not living in the UK.
What he got: These demands were never going to fly in Brussels because they violated the principle that all EU workers should treated equally across the union. But what he did get was a complicated (and rather ingenious) idea of an emergency brake where a member state could apply to the Commission for permission to suspend benefit payments if they were placing too much burden on the social services of a member state. Conveniently the Commission confirmed Britain would be eligible for this before the talks even started. The haggling over the last 24 hours was over how long this break should last for. Cameron initially called for the emergency brake in place for 13 years, but the Visegrád group of four central European countries (Poland, Hungary, Slovakia and the Czech Republic) arrived at the summit with a starting bid of five years. In the end the Council settled on seven - a compromise the British will not be unhappy with.
On child benefits he was less successful. Before the summit started he had to back down on a total ban and agree that payments would be indexed to what migrants would get at home. In addition the change will be phased in for existing claimants from 2020. In reality this will save the exchequer very little money and, given it will be complicated to administer, could actually cost more to run than it will save.
Win rating: 2/5
Protection from further Eurozone integration
What he wanted: Key to British demands were new rules to protect countries outside the Eurozone against regulation made by those inside the group that could disadvantage them. Specifically, he wanted any non-Eurozone country to be able to stall new regulations for the currency union, by triggering further discussions among EU leaders of the proposals. This was principally designed to protect the City from an attempt by the Eurozone to challenge its dominance as Europe's main financial centre.
What he got: In a surprising win for Cameron, only one euro ‘outer’ will be needed to force a debate among EU leaders about ‘problem’ Eurozone laws. Other EU leaders agreed to this because neither the UK, nor any other country, would have an absolute veto. These protections, however, will also be written into EU treaties, so Britain could if it needed to challenge a decision in the European Court if it feels that it is discriminatory - again a key demand of the Prime Minister.
Win rating: 4/5