It was with the noble aim of making war “not only unthinkable but materially impossible” that the European project was born. A historically riven continent has since enjoyed an unprecedented period of peace. The European Coal and Steel Community of 1951 has evolved into today’s European Union: an organisation and single market of 28 states and 508 million citizens. It is this unique institution – a force for stability, global governance and rules-based order – that the UK could leave on 23 June. It would be the first country to do so.

The referendum is not being held for reasons of principle. David Cameron reluctantly agreed to it in order to appease his recalcitrant backbenchers and the right-wing press, and to counter the threat of the UK Independence Party, which is, in essence, a single-issue pressure group that has been brilliantly led by Nigel Farage, no matter what you think of his politics. The ensuing campaign has distracted attention from the UK’s most pressing economic and social problems.

If the polls are to be believed, we could well be facing Brexit.

The reasons are not hard to discern. The UK was late to join the European project and has long been its most reluctant member. For decades, the media and politicians, including Mr Cameron, have spoken disparagingly of “Brussels”. Few have made a positive case for the EU. They have blamed it for domestic failures and credited themselves with European successes. Even allowing for this propaganda, however, the EU has rarely endeared itself to voters. It has been too opaque in its decision-making, too wasteful in its spending and too remote from its citizens. Confronted by a eurozone crisis of its own making, it reacted dismally. Its handling of the refugee surge – the largest that Europe has faced since the Second World War – has been similarly inept. Never has the EU been more discredited. Who now speaks of the European dream?

Yet if the UK votes to leave, it will pay a price. Almost all economists forecast that Britain would suffer an immediate shock, and reduced growth and living standards in the long term. The Institute for Fiscal Studies predicts a deterioration of between £20bn and £40bn in the public finances by 2020, raising the spectre of further cuts or tax rises. Britain would be forced to spend years renegotiating trade deals.

The most candid Brexit campaigners, many of whom have little to fear from recession, maintain that this is an acceptable price for regaining “sovereignty”. All empires fall, they say, and they fall because they spurn democracy. The UK alone, they argue, should determine its laws. In most cases it does. Britain has rightly joined neither the single currency nor the border-free Schengen Area. Any further transfer of power would be subject to the so-called referendum lock introduced by Mr Cameron.

In selected areas, the UK has not relinquished sovereignty but pooled it, just as it does in Nato and other transnational organisations. Britain trades influence over its affairs in return for influence over those of 27 other states and in the world. The single market, climate change, tax avoidance, security and cross-border crime are all issues that demand common laws and standards. This enlightened approach has advanced prosperity, social justice and human rights across the continent.

In the case of Britain, it has also significantly increased immigration, which worries a large number of voters of all ages. As Labour is discovering, many of its core supporters, especially in the north of England, are restive and favour Brexit. The reason for this is immigration and freedom of movement. These long-time Labour voters feel alienated from liberal metropolitan values and left behind by ­globalisation. They feel that politicians of all parties are not listening.

Net migration last year stood at 333,000, the second-highest figure on record, with EU migrants accounting for over half of all newcomers to Britain. The Leave campaign has vowed to end free movement, as well as to introduce an Australian-style points system, so that immigration might be more tightly controlled. Yet were Britain to reduce immigration, it would do so at the cost of reducing growth. Migrants contribute far more in taxes than they receive in benefits and provide youthful labour to support an ageing population. The Leave side has run a shamefully demagogic campaign, implying that Turkey (“population: 76 million”) is on the brink of EU accession. It is not – and the UK retains a veto over all prospective members.

Although most Brexit supporters lie on the right of British politics, left-wingers, too, advocate withdrawal. Alongside the Bennite isolationists are more recent converts repulsed by the austerity imposed on Greece and other countries. They feel that the European Court of Justice and the European Central Bank have acquired far-reaching powers without the necessary attendant democratic scrutiny.

We have long argued against the EU’s fiscal retrenchment but Brexit would be little more than a futile gesture in the present circumstances, with Europe destabilised by multiple crises. Britain needs to stay in the EU so that it can lead the reform of the bloc. If that is not possible, the EU ultimately may be brought down by its own contradictions and its imperial overreach.

There have been moments in Britain’s history when the country could have withdrawn in relatively benign circumstances. This is not one of them. Should Scotland vote to remain while the rest of the UK votes to leave, a second independence referendum and the break-up of the Union could result. Brexit would threaten the hard-won peace in Northern Ireland by encouraging the return of border controls. The UK’s departure would embolden fascists and populists across the continent, most notably Marine Le Pen in France, and enhance Russia’s revanchist ambitions. It is far from inconceivable that Brexit could set in train the break-up of the EU.

Europe is paying not just for its failures but for its many successes, not least in keeping the peace and solving the German Question by embedding Germany in the institutions of the EU. The peace and prosperity that our ancestors strove for are too often taken for granted. For the sake of all that the EU has achieved and could yet achieve, the United Kingdom should vote to remain on 23 June.