There is no point trying to deny it. Paul Nuttall’s election as Ukip leader is dangerous for Labour. Yes, Nuttall may not be a credible voice for working-class people – he ran as a Tory councillor in 2002 and has said that “the very existence of the NHS stifles competition”. Yes, he may be leader of a party which has (for now) haemorrhaged donors and supporters. But what Nuttall’s election represents is the coming of age for a form of right-wing populism which is pointed directly at Labour’s base. Along with the likes of Ukip's major donor Arron Banks, Nuttall will open up a second front against Labour – focused on blaming migrants for falling wages and crumbling services.

In the face of this danger, and the burning need to create a narrative of its own about the neglect of the communities it represents, Labour’s main response has been confusion. Barely a week has gone by without a major Labour figure repeating the touchstone myths on which Ukip has built its working class roots. Speaking on the Andrew Marr Show, Emily Thornberry openly backed the idea that migration has dragged down wages. “Do I think that at the moment too many people come into this country? Yes I do”, she said.

Another response has been to look for policies that transcend the debate altogether, while giving a nod to the perceived “concerns” that voters harbour about immigration. When Clive Lewis spoke to the Guardian some weeks ago, he also repeated the idea that free movement “hasn’t worked for many of the people in this country, where they’ve been undercut” and coupled this with compulsory trade union membership for those coming to Britain to work – a closed shop for migrant workers.

It is unsurprising that MPs on the right of the party – many of whom had much to say about the benefits of migration during the EU referendum – have retreated into support for immigration controls. This kind of triangulation and retreat – the opposite of the insurgent leftwing populism that Labour needs to win elections – is the hallmark of Labour’s establishment politics. Those who want to stand and fight on the issue should be concerned that, for now, only Diane Abbott has come out fighting for continued free movement.

At the moment, Labour is chasing the narrative on immigration – and that has to stop. The process that is shifting the debate on migration is Brexit, the British franchise of a global nationalist resurgence that is sweeping the far right to power across the western world. Attempt to negotiate a compromise on migration in the face of that wave, or try to claim it as an “opportunity”, and there is simply no limit to how far Labour will be pushed. What is needed is an ideological counter-attack, which tells a different story about why living standards have deteriorated and offers real solutions.

The reason why wages have stagnated and in recent decades is not immigration. Among the very few studies which find that migration has caused a fall in wages, most conclude that the fall is marginal. The Bank of England’s study, cited by Boris Johnson in the heat of the EU referendum campaign, put the average figure at 0.3 per cent for every ten percentage point rise in migrants in a given sector of work. That rises to 1.8 per cent in some areas.

Median earnings fell by 10.4 per cent between 2007 and 2015, and by 2021 are forecast to be lower in real terms than they were in 2008. For many communities, that fall in wages comes on top of the destruction of industry; the defeat of the trade union movement; the fire sale of Britain’s social housing stock; and years of gruelling Tory austerity. Nuttall’s Ukip will argue that economic and social insecurity are the result of uncontrolled immigration. To give an inch to that claim is to abandon reality.

Labour cannot win against Ukip by playing around with new and innovative border controls – it has to put forward a vision for a radically different kind of society. Under Jeremy Corbyn, Labour is closer than it ever has been to the kind of radical social and economic platform that it will need to regain power - £500bn of investment, building a million new homes a year, raising minimum wage and reinstating proper collective bargaining and trade union rights. What it needs now is clarity – a message about who to blame and what to do, which can cut through the dust kicked up by the Brexit vote.