It looks like Sir Keir Starmer is growing a backbone and doing what needs to be done. Now he has an opportunity to reshape his party and leave a lasting legacy even if he never wins an election. If he manages it, he’ll have been a far more successful leader than his three failed predecessors. And by creating a viable opposition he’ll have left an important mark on British politics too.

At Starmer’s behest, hundreds of far-left supporters of Jeremy Corbyn will be expelled from Labour after its ruling body agreed to ban four groups accused of promoting a “toxic culture” within the Party. The ruling National Executive Committee (NEC) proscribed ‘Resist’ and ‘Labour Against the Witchhunt’ for claiming anti-Semitism allegations that have toxified the Party were politically motivated.

‘Labour in Exile’, which recruits expelled or suspended members, was also banned. Another group, the openly Marxist ‘Socialist Appeal’, was also proscribed. Momentum – the biggest far-left Labour group – said it was a “cynical and desperate” attempt to “smash the left”.

If he wants to finish the job, he’d purge Momentum from the Party too. Alan Johnson was right when he called Momentum a “cult” that alienated working class voters. “I want them out of the party. I want them gone. Go back to your student politics,” he said. Hear, hear!

Momentum, created to support Corbyn’s leadership and which continues to promote his values, has – of course – questioned the motives behind the expulsions. It claimed a “deafening silence from the leadership on anti-Muslim prejudice in Labour indicate deep problems at the top of the party when it comes to tackling racism”. Classic whataboutery for a group that has always been a blockage to dealing with a toxic culture of racism, online trolling and dogmatism within the official opposition.

The group also said: “There are now some in the media and the party openly arguing for the proscription of Momentum, and over the coming months we expect the anonymous briefings calling for this to increase.” I sure hope so.

Labour will be far better off without Momentum and can be reborn if Starmer does the right thing and ensures that Jeremy Corbyn himself is expelled. Corbyn remains suspended from the party whip following his reaction to an equalities watchdog finding of institutional anti-Semitism under his leadership.

With the government going strong despite so many blunders and much bad publicity, Starmer is best off ensuring the moderates win the still raging civil war within his party. Expelling those four groups was a good move, but he must get rid of their supporters and apologists too so Labour can rebuild, begin to look like the kind of party that doesn’t seem like a bunch of ideological weirdos, racists and eccentrics obsessed with niche issues.

This housekeeping is essential. The disastrous legacy of Ed Miliband and Jeremy Corbyn must be dismantled. Membership rules should be tightened up and the Party rules vigorously enforced and then, and only then, might it have a chance of electoral success. Labour must change and it must be seen to change in the public eye. It may come too late for Starmer, but he can pave the way to an electorally viable future.

The people that are sympathetic to the proscribed groups and would spit feathers at the expulsion of Momentum and Corbyn are exactly the kind of members Labour can do without. It’s only by defeating the far-left and openly rejecting their values that it can become more than a protest movement. They must have a broader appeal to win elections.

If Starmer does this, he might then be able to create his own agenda and have a better chance of the public listening. He may fail at the next election, but he will have done a great service to the Labour Party and the country.