In a result that sent shockwaves across Britain and the EU, it emerged that 52% of the British public had voted for Brexit.
The total number of votes cast in favour of Remain was 16,141,241, with 17,410,742 votes cast in favour of Leave.
It dealt a huge blow to the European project and lead to huge political division.
For many, it was a day of euphoria and celebration.
UKIP leader Nigel Farage said the day should go down in history as Britain's "Independence Day" and he declared: "We've got our country back."
.
British Prime Minister David Cameron announced he would resign by October, saying: "I will do everything I can as prime minister to steady the ship over the coming weeks and months, but I do not think it would be right for me to try to be the captain that steers our country to its next destination."
.
Another Remainer, Theresa May, took the helm.
She promised to "rise to the challenge" of negotiating the UK's exit.
On 20 July, she repeated the slogan she used during her leadership campaign, telling the House of Commons: "I'm very clear Brexit does mean Brexit… we will make a success of it."
.
The High Court ruled against the British government and said the Parliament had to hold a vote before Article 50, the notice that Britain was leaving the EU, was triggered.
Theresa May said this would not stop her invoking the legislation.
The president of Britain's Supreme Court described the landmark case as a matter of law and not politics.
The lead challenger against the government was businesswoman Gina Miller who received death threats and abuse.
Labour leader Jeremy Corbyn said the so-called Brexit vote to leave the EU had changed the political landscape, calling it a political earthquake whose aftershocks were still being felt.
He told a London conference: "We could focus on trying to re-run the arguments of the referendum, oppose Brexit at every turn and be a party that represents the 48% who voted to Remain in the referendum and only the 48%.
"Or we can rise to the democratic challenge set before us to represent the whole country and bring people together by putting forward a progressive vision for a post-Brexit Britain."
.
Prime Minister May triggered Article 50 leading the European Council president Donald Tusk to express his unhappiness at a press conference in Brussels where he said: "We already miss you. Thank you and goodbye."
.
Theresa May announced a snap general election to be held on the 8 June that year.
Her gamble on a snap general election backfired spectacularly and Mrs May lost her Commons majority.
She became the first head of a Conservative administration to be propped up by the DUP.
.
In a crucial Brexit speech in Florence, Theresa May sends a message to EU leaders saying: "We want to be your strongest friend and partner as the EU and UK thrive side by side."
She proposes a two-year "implementation period" of "around two years" where existing market arrangements will apply.
.
On a visit to Dublin, the President of the European Council says that if the UK's Brexit offer is unacceptable to Ireland, it will be unacceptable to Europe.
Donald Tusk promises to consult Dublin on any offer put forward by the UK.
Thanking Donald Tusk for his unwavering support, the Taoiseach Leo Varadkar says: "On the question of the border, as I said many times, the best and most obvious solution would be for the United Kingdom to remain in the Customs Union and the Single Market.
"But as the British government has ruled that option out, it must offer credible, concrete and workable solutions that guarantee that there will be no hard border, whatever the outcome of the negotiations, and whatever the future relationship between the EU and the UK is."
.
The year ends on a slightly more optimistic note as the European Commission President Jean-Claude Juncker gives an update on progress, saying: "We discussed the joint report agreed by the two negotiators. Prime Minister May has assured me that it has backing of the UK government. On that basis I believe we have now made the breakthrough we needed. Today's result is of course a compromise.".
The EU's chief negotiator Michel Barnier said he and then-Brexit secretary David Davis had taken a "decisive step" towards agreeing a joint legal text on Withdrawal but he warned that there are still outstanding issues around the border in Ireland.
.
Theresa May held a crunch Cabinet meeting at Chequers in which her new Brexit plan is agreed, including the creation of a new UK-EU free trade area for goods.
She says: "Our proposal will create a UK-EU free trade area, which establishes a common rule book on industrial goods and agricultural products. This will maintain high standards but we will ensure that no changes can take place without the approval of our parliament."
However, there are rumblings of dissent.

David Davis, who has been leading UK negotiations, quit his role as Brexit Secretary, saying he did not agree with Mrs May's plan which he said "was giving away too much and too easily" to the EU in negotiations.
A second high-profile resignation followed as Boris Johnson quit as Foreign Secretary - leaving the plans in disarray and the Conservative government in crisis.
.
The DUP leader Arlene Foster told the BBC that there could be no Brexit deal that would divide Northern Ireland from the United Kingdom.
She said there could not be a border down the Irish sea, a differential between Northern Ireland and the rest of the UK." Asked whether this was a red line, she replied: "The red line is blood red."
.
Following a five-hour Cabinet meeting, Theresa May announces a draft Brexit Withdrawal Agreement has been agreed.
However, 24-hours later, her new Brexit Secretary Dominic Raab also resigns saying he cannot support the terms of the deal.
Prime Minister May says: "I firmly believe that the draft Withdrawal Agreement was the best that could be negotiated and it was for the cabinet to decide whether to move on in the talks.
"The choices before us were difficult, particularly in relation to the Northern Ireland backstop but the collective decision of cabinet was that the government should agree the draft Withdrawal Agreement and the outlying political declaration."

British Prime Minister Theresa May abruptly defers a parliamentary vote on her Brexit deal, again throwing Britain's plan to leave the European Union into chaos when she admitted that she faced a defeat.
.
Theresa May survives an attempt to oust her in a confidence vote triggered by the powerful so-called 1922 Committee.
MPs reject Theresa May's Brexit plans by an emphatic 432 votes to 202 in an historic vote which throws the future of her administration and the nature of the UK's withdrawal into doubt.
It was the worst parliamentary defeat for a government in recent British history.Scores of her own party members - both Brexiteers and supporters of EU membership - joined forces to vote down the deal.
The opposition Labour party tables a motion of no confidence in Mrs May's government.
.
Britain's parliament rejected Theresa May's deal for a second time, deepening the country's worst political crisis for generations - 17 days before the planned departure date.
.
MPs voted overwhelmingly to seek a delay in Britain's exit from the European Union, setting the stage for Prime Minister Theresa May to renew her efforts to get her divorce deal approved by parliament the following week.

Commenting on a so-called "Brextension", Theresa May said: "Two years on MPs have been unable to agree on a way to implement the UK's withdrawal. As a result, we will now not leave on time with a deal on 29 March. This delay is a matter of great personal regret for me and of this I am absolutely sure: you the public have had enough."
She told the House of Commons she had written to request an extension to Article 50 negotiations until 30 June.
.
Mrs May's Withdrawal Agreement was rejected for the third time.
.
The EU agreed a flexible extension of "flextension" until 31 October.
.
Theresa May sets out a "bold, new offer" for Britain's departure from the European Union, offering sweeteners to opposition parties in her fourth attempt to break an impasse in parliament over Brexit.
She said the new deal would work to find an alternative to the Irish backstop, whilst also promising Northern Irish unionists that the deal would prevent the country from being split from the UK's customs union, if the backstop was to come into force.
However, the proposal does not meet the DUP's central demand of removing the Northern Ireland backstop from the Withdrawal Agreement.
Labour leader Jeremy Corbyn calls it a "rehash" of what was discussed before.
.
Theresa May announced she was standing down as Tory leader on 7 June saying it is a matter of "deep regret" that she had not been able to deliver Brexit.
Theresa May to stand down as Conservative Party leader | Read more: https://t.co/pyPnzAKkBm pic.twitter.com/s1sefb3Aqj
— RTÉ News (@rtenews) May 24, 2019
Theresa May left Number 10, close to tears, as she said being Britain's second female prime minister had been the honour of her life.
She had said she was leaving with: "No ill-will, but with enormous and enduring gratitude to have had the opportunity to serve the country I love."
.
Former Foreign Secretary Boris Johnson was elected Conservative Leader and became British Prime Minister, after defeating rival Jeremy Hunt.
The following day he vowed: "I will take personal responsibility for the change I want to see. Never mind the backstop. The buck stops here."
.
European Commission president Jean-Claude Juncker predicted a no-deal Brexit would hurt Britain more than the rest of Europe, no matter how much the new prime minister's government pretended otherwise.
In a newspaper interview, he said: "We are fully prepared, even though some in Britain say we are not well set up for a "no-deal".
That summer he rebuffed Boris Johnson's demands for changes relating to the border in Ireland in a new Brexit deal.
.
The British monarch was dragged into the Brexit row as Boris Johnson requested the prorogation of parliament from early September until mid-October.
He denied he was seeking to prevent parliament from obstructing his Brexit plans, by cutting into sitting time before the Brexit deadline of 31 October.
The suspension of parliament was ultimately ruled unlawful by the Supreme Court as it had the effect of frustrating Parliament.
.
MPs voted to approve legislation aimed at preventing a no-deal Brexit, underlining the lack of support for Boris Johnson's vow to take Britain out of the European Union with or without a deal.
.
The then-taoiseach Leo Varadkar said he would not replace a legal guarantee for the Irish backstop, an insurance agreement to prevent the return of border controls between Northern Ireland and the Irish Republic, without a specific alternative.
He said: "In the absence of agreed alternative arrangements, no backstop is no deal for us. All it does is kick the can down the road for another 14 months; another 14 months of uncertainty for business, another 14 months of uncertainty for people north and south of the border, so that's not an option that we find attractive at all."
.
Boris Johnson put forward his formal Brexit plan to the EU.
He spoke by phone that evening with the Taoiseach Leo Varadkar who said the proposals did not fully meet the agreed objectives of the backstop, but agreed to study them further whilst consulting with EU leaders.
.
After intense negotiations in the run-up to a summit of EU leaders, Boris Johnson and European Commission President Jean-Claude Juncker announced that they had struck a Brexit deal.
Mr Juncker said: "We have a deal and this deal means that there is no need for any kind of prolongation. This is a fair, a balanced agreement. It is testament to our commitment to finding solutions. It provides certainty where Brexit creates uncertainty. It protects the rights of our citizens and it protects peace and stability on the island of Ireland."
Under the new agreement, Northern Ireland would remain in the UK customs area but tariffs would apply on goods crossing from mainland Britain to Northern Ireland if they were deemed to be headed further, to Ireland and to the bloc's Single Market.

Boris Johnson sends an unsigned letter to the European Union, requesting a delay to Britain's exit from the bloc but he added another note in which he explained that he did not want a "deeply corrosive" Brexit extension.
Johnson had previously said he would rather be "dead in a ditch" than ask for any extension to the 31 October deadline.
.
Boris Johnson mounted an attempt to fast-track his Brexit deal through parliament, but he was forced to put his plans on hold when parliament rejected his extremely tight timetable for ratifying his exit deal, which would have seen it rushed through the Commons in just three days.
.
European Council President Donald Tusk announced agreement for a second Brexit "flextension" until 31 January.
.
Boris Johnson succeeded on his fourth attempt to win Commons support for a snap general election on 12 December.
.
Having campaigned on the promise to "Get Brexit Done," Boris Johnson secured the 80-seat majority necessary to do so.
Labour Party leader Jeremy Corbyn, who had promised a second Brexit referendum, suffered his party's worst defeat in decades as voters in former industrial areas of central and northern England, areas that typically voted for Brexit, swung towards Johnson's conservatives.
.
In his New Year message, Boris Johnson said: "That oven-ready deal I talked about so much during the election campaign has already had its plastic covering pierced and been placed in the microwave."
.
New European Commission President Ursula von der Leyen visited London where she warned Boris Johnson that the timetable for securing a post-Brexit trade deal was "very, very tight".
Boris Johnson made it clear there would be no extension to the Transition Period, which expires at the end of this year.
The prospect of a cliff-edge is used during the negotiations to demand a comprehensive Free Trade Deal, all to be negotiated in less than 11 months.
.
Boris Johnson gets his Brexit deal through the Commons, as the European Union (Withdrawal Agreement) Bill is given a third reading with a majority of 99.

The UK finally departed the EU at 11pm.
A countdown clock was projected onto the walls of Downing Street whilst there were street parties held by Vote Leave supporters.
.
EU negotiator Michel Barnier held talks with Boris Johnson's Brexit negotiator David Frost in Brussels on Britain's formal relationship with the EU, including the building of a Free Trade Agreement.
.
The two sides announced they would suspend face-to-face talks due to the Covid-19 pandemic and negotiations continued via video conferencing.
.
Cabinet Minister Michael Gove officially tells the EU that the UK will not sign up to any extension to the Transition Period but he backtracks on plans to immediately introduce full border checks from 1 January.
Talks intensify during the summer, despite the ongoing Covid-19 crisis.
.
Boris Johnson admits there needs to be an agreement with Europe by the time the European Council meets on 15 October if it's going to be in force by the end of the year.
In a statement he said: "If we can't agree by then, then I do not see that there will be a free trade agreement between us, and we should both accept that and move on," whilst talking about the prospect of an Australian style trading arrangement.
Australia trades with the European Union under World Trade Organisation terms.
.
Talks hit crisis point when Britain admitted it could break international law by undercutting its divorce treaty with the European Union.
Northern Ireland Secretary Brandon Lewis, who delivered the news in the House of Commons said: "Yes, this does break international law in a very specific and limited way. We are taking the powers to dis-apply the EU law concept of direct effect required by article 4 in a certain, very tightly defined circumstances.
"There are clear precedents for the UK and indeed other countries needing to consider their international obligations as circumstances change."
The former British Prime Minister Theresa May was among those who questioned how the UK could now be trusted to abide by the legal obligations of the agreements it signs.
.
Trust was further shaken when Boris Johnson accused the EU of "being willing to go to extreme and unreasonable lengths, using the Northern Ireland protocol in a way that goes well beyond common sense simply to exert leverage against the UK in our negotiations for a Free Trade Agreement."
.
The US Democratic presidential candidate Joe Biden warned the United Kingdom in a tweet that it must honour the Northern Irish peace deal, saying the Good Friday Agreement could not be allowed to become a casualty of Brexit.
We can't allow the Good Friday Agreement that brought peace to Northern Ireland to become a casualty of Brexit.
— Joe Biden (@JoeBiden) September 16, 2020
Any trade deal between the U.S. and U.K. must be contingent upon respect for the Agreement and preventing the return of a hard border. Period. https://t.co/Ecu9jPrcHL
He added that any future trade deal between the US and the UK would be contingent upon respect for this agreement and the prevention of a hard border.
Here, the Minister for Foreign Affairs Simon Coveney said trust had been damaged and he spoke of disappointment across the EU at the developments.
He said: "The bringing forward of legislation to deliberately undermine an international agreement with the EU has caused a lot of concern, it has damaged trust and relationships in the context of these negotiations and I think that's very regrettable."
The European Union went ahead launching its threatened legal case against the UK over its new Internal Market Bill.
European Commission President Ursula von der Leyen said: "This draft bill is by its very nature a breach of the obligation of good faith laid down in the Withdrawal Agreement. Moreover, if adopted as is, it will be in full contradiction to the protocol of Ireland/Northern Ireland."
Boris Johnson said the UK should prepare for a no-deal Brexit and Australia-style future with the EU.
The message from London came as EU leaders met to discuss the stalling of negotiations with the UK.
.
Face-to-face talks between Michel Barnier and David Frost on securing a post Brexit trade deal are held in London as hopes on a breakthrough start to fade.
They continue until 4 December and end without agreement.
.
Britain's chief Brexit negotiator David Frost travelled to Brussels for last-ditch talks as time ran out to find an agreement over the three key sticking points which remained unresolved: fishing quotas, competition rules, and ways to solve future disputes.
Here, the Minister for Foreign Affairs said a deal is in everyone's interests.
.
In a joint statement following a phone call, European Commission President Ursula von der Leyen and British Prime Minister Boris Johnson said the conditions for finalising an agreement are not yet there due to significant differences in the areas of fisheries, governance and the so-called level playing field.
They agree to meet in Brussels over dinner.
.
An agreement is reached in principle on the operation of the Northern Ireland protocol which forms part of the Brexit Withdrawal Agreement.
This would mean the avoidance of a hard border for checks on animals and plants, and the supply of medicines.
It also relates to the supply of chilled meats, and other food products to supermarkets in the North, helping to allay concerns about supply shortages there.
The British Government confirmed it would withdraw controversial measures that could have seen the divorce deal torn up and the UK break international law.
.
Boris Johnson told people and businesses to prepare for a no-deal Brexit on 1 January.
In a video message after three-hour talks with European Commission chief Ursula von der Leyen he said that there was a "strong possibility" of what he called an "Australia-style" deal.
.
The Taoiseach Micheál Martin, who had earlier described talks as being 50/50 and on a 'knife edge' admitted a no-deal was now the most likely outcome.
He said: "We are preparing for a no deal Brexit. The budget that we passed was based on the premise of a no deal Brexit because we have to prepare for all scenarios. We also don't want a no deal outcome, but we have to prepare for it, and it would be a further hit on the economy on top of Covid-19."
The UK's foreign secretary Dominic Raab said the British government would "rather have a free trade deal" with the European Union, but added that Britain would not "sacrifice basic democratic principles".
Taoiseach Micheál Martin tells RTÉ's Morning Ireland that a dispute resolution mechanism could be used to "square the circle" on the EU-UK disagreement over the so-called level playing field, saying there was a low risk of the UK adopting lower standards than the EU.
He said any potential divergence could be addressed by a dispute resolution mechanism.
"The circle will be difficult to square but I think we need to stand back too from the high principle around this and say: 'Look, Britain is a first-world economy. Its economy has been integrated with the European economy for the last 50 years and a lot of standards - on the environmental front, for example - the UK would be ahead of some member states'."
British Prime Minister Boris Johnson insists that the EU knew the parameters of the ongoing talks and indicated Britain could leave the EU on Australian terms.
He adde: "We've just got to make sure that we control our own laws and control our own waters, and there's a good deal there to be done. But if not, WTO/Australia terms it is, and as I say we will prosper mightily on those terms as well."
.
The EU's Brexit negotiator says: "We are at a moment of truth. We have very little time left, a few hours." However, he says the EU must be prepared for any scenario, adding: "The path to such an agreement is very narrow".
Michel Barnier's offer on fisheries, which is said to be final, is reported by RTÉ to mean a cut of 25% in the value of fish caught by EU boats in UK waters, worth an overall €160 million. This would mean a cut in mackerel stocks worth €47 million, while sole in the North Sea would be cut by €12 million, herring by €8 million and prawn by €5 million.
Groups representing the Irish fishing industry said the offer would spell their ruination. Britain, meanwhile, was reported to be looking for a figure closer to 60%.
.
A midnight deadline set by the European Parliament came and went, with the European Parliament confirming it would not be in a position to grant consent to an agreement this year. The parliament had warned it was not prepared to ratify any treaty in time for the end of the Transition Period on 1 January, without having adequate time to consider it. Senior UK government sources said the talks remained difficult, but they were expected to continue.
Meanwhile, long lines of trucks, which had already been building during the week at Dover and Folkstone in Kent, due to an increase in pre-Brexit freight, became trapped there when news broke that the ferry terminal at Dover would close to all traffic leaving the UK, due to border restrictions in France, over fears around the spread of a new variant of Covid-19 in the southeast of England.
The Eurotunnel tweeted that its last shuttle service departing for France would leave at 9.34pm that night, with access to its UK site prohibited from 10pm.
.
The French government again insisted it was sticking to its "red lines" when it came to EU rights to fish in British waters.
Scotland's First Minister Nicola Sturgeon called for an extension of the Brexit transition period, due to the emergence of a new Covid-19 strain which led to several European countries announcing temporary border closures with Britain in order to stop its spread.
The traffic gridlock at the port of Dover becomes even more chaotic when France closes its border.
.
EU chief negotiator Michel Barnier briefed ambassadors from EU member states on trade talks with the United Kingdom.
Earlier, he pledged to continue to push for a post-Brexit trade deal in the last 10 days before Britain leaves the single market, saying: "We are really in a crucial moment and we are giving it a final push."
.
There were optimistic rumblings about the possibility of a deal with talks said to be in their final stages.
However, despite French reports of British concessions, there was no evening statement from either European Commission President Ursula von der Leyen or British Prime Minister Boris Johnson.
Taoiseach Micheál Martin said there were growing signs that the talks could be reaching a conclusion, with fish being the central issue.
He told RTÉ News: "It's gone down to the wire on fish and the sticking points around that but the signs today, all day, have been much more encouraging in relation to these talks being brought to a close."
"Deal is done," a Downing Street source said. "We have taken back control of our money, borders, laws, trade and our fishing waters."
"The deal is fantastic news for families and businesses in every part of the UK. We have signed the first free trade agreement based on zero tariffs and zero quotas that has ever been achieved with the EU."
"We have delivered this great deal for the entire United Kingdom in record time, and under extremely challenging conditions, which protects the integrity of our internal market and Northern Ireland's place within it," the source said.
Additional reporting Reuters and PA