The future of Britain in Europe rests in the hands of millions of voters, still undecided after a gruelling, often divisive referendum campaign, which, whatever the result, will leave the country changed forever.

Polling on the final day of campaigning showed the rival campaigns in a near dead-heat, with Opinium putting Leave on 45 and Remain on 44, while a survey for TNS had Leave on 43 and Remain on 41. Nine per cent of voters in the Opinium poll were still undecided.

In a final push to secure support before polls open, David Cameron joined with every living former Prime Minister to urge a vote for Remain, claiming to be at the head of “the biggest coalition of support in history”.

Meanwhile, Boris Johnson, the figurehead of the Vote Leave campaign, and considered Mr Cameron’s likely successor if Britain votes to leave, finally confirmed speculation that he had written two articles before the campaign: one declaring support for Leave, and the other for Remain.

David Cameron meets voters on the final day of campaigning (AFP/Getty Images)

In a confession that will revive accusations that he backed Leave to improve his chances of becoming Prime Minister, Mr Johnson admitted he had written an article in which he placed his support for Mr Cameron over and above his qualms about the EU.

“I’ll tell you what the second article said,” he told BBC Newsnight. “What it said was: ‘actually irrespective of my objections to the way the EU was going in order to support my party and the Prime Minister it would be better to stay in’. And in the end I thought that wasn’t a good enough reason.”

What has the EU ever done for us? Show all 7 1 /7 What has the EU ever done for us? What has the EU ever done for us? 1. It gives you freedom to live, work and retire anywhere in Europe As a member of the EU, UK citizens benefit from freedom of movement across the continent. Considered one of the so-called four pillars of the European Union, this freedom allows all EU citizens to live, work and travel in other member states. What has the EU ever done for us? 2. It sustains millions of jobs A report by the Centre for Economics and Business Research, released in October 2015, suggested 3.1 million British jobs were linked to the UK’s exports to the EU. What has the EU ever done for us? 3. Your holiday is much easier - and safer Freedom to travel is one of the most exercised benefits of EU membership, with Britons having made 31 million visits to the EU in 2014 alone. But a lot of the benefits of being an EU citizen are either taken for granted or go unnoticed. What has the EU ever done for us? 4. It means you're less likely to get ripped off Consumer protection is a key benefit of the EU’s single market, and ensures members of the British public receive equal consumer rights when shopping anywhere in Europe. What has the EU ever done for us? 5. It offers greater protection from terrorists, paedophiles, people traffickers and cyber-crime Another example of a lesser-known advantage of EU membership is the benefit of cross-country coordination and cooperation in the fight against crime. What has the EU ever done for us? 6. Our businesses depend on it According to 71% of all members of the Confederation of British Influence (CBI), and 67 per cent of small and medium-sized enterprises (SMEs), the EU has had an overall positive impact on their business. What has the EU ever done for us? 7. We have greater influence Robin Niblett, Director of think-tank Chatham House, stated in a report published last year: “For a mid-sized country like the UK, which will never again be economically dominant either globally or regionally, and whose diplomatic and military resources are declining in relative terms, being a major player in a strong regional institution can offer a critical lever for international influence.

Mr Johnson claimed that Leave were on the “verge of victory”

In a rally speech in Selby, North Yorkshire, he said: “This will not come again. Vote Leave tomorrow, take back control of our country and our democracy and stick up for hundreds of millions of people around Europe who agree with us, who agree that the EU is going in the wrong direction.”

Mr Cameron, meanwhile, was backed by Gordon Brown, Tony Blair and Sir John Major and leaders in science, economics, medicine, charity, business, the military, security, the heads of trades unions and faith leaders in urging Britain to vote for a “brighter and more secure future in the European Union”.

“Today we have assembled the biggest coalition of support in history – from businesses, to trade unions, to expert economists and across political parties – for a vote to Remain,” the Prime Minister said.

Mr Brown said the vote was a “momentous, generation-defining decision about what kind of country we are”. Mr Blair said a vote to leave would mean “a reckless leap in the dark and years of damaging uncertainty”, while Sir John said that millions of British people had the opportunity to “save our country from a mistake we would live to regret for a very long time to come”.

The rival camps traded blows again on the final day of campaigning, which opened with controversy when Justice Secretary Michael Gove compared economic experts warning over Brexit to the German scientists who, under the Nazis, denounced Albert Einstein in the 1930s.

Mr Gove later apologised for the comments, after Mr Cameron suggested that his friend and colleague had “lost it”.

As the leaders of the rival campaigns toured the country, a rally was held in London in memory of Jo Cox, whose 42nd birthday it would have been. Addressing a crowd of thousands Ms Cox’s husband, Brendan, said that she would have spent the day “dashing around the streets of her hometown trying to convince people that Britain is stronger in Europe.”

“She feared the consequences of Europe dividing again, hated the idea of building walls between us and worried about the dynamics that that could unleash,” he said.

However, he said the rally was not about the referendum, but about a “much wider battle against hatred that she was engaged in”.

Describing his wife’s killing as “political” and an “act of terror”, he said: “She’s come to symbolise something much bigger in our country and our world, something that is under threat, her belief in tolerance and respect, her support for diversity and her stand against hatred and extremism no matter where it comes from,” he said.

“Across the world we’re seeing forces of division playing on people’s worst fears rather than their best instincts, trying to divide our communities, to exploit insecurities and emphasise not what unites but what divides us.”