Jeremy Corbyn will quit if Labour loses the general election expected within months, says his key ally John McDonnell – promising to follow him out of the door.

The shadow chancellor insisted Labour could win a Commons majority – despite the party’s disastrous poll ratings – but admitted the price of failure would be resignation.

Asked if Mr Corbyn could “stay on”, Mr McDonnell replied: “I can’t see so. What we’d do is as the tradition, which is have an election for a new leader.”

Speaking to Alastair Campbell, in an interview for GQ magazine, he also said: “I think it is the same for my own personal position.”

Mr McDonnell also insisted he backed Mr Corbyn’s determination to fight an election before a fresh Brexit referendum is held – but admitted a Final Say referendum could yet come first.

Brexit and climate protests at Labour party conference: In pictures Show all 12 1 /12 Brexit and climate protests at Labour party conference: In pictures Brexit and climate protests at Labour party conference: In pictures Labour leader Jeremy Corbyn walks past anti-Brexit campaigner on the second day of the party conference in Brighton AFP/Getty Brexit and climate protests at Labour party conference: In pictures A protester holds a sign mocking Labour leader Jeremy Corbyn's Brexit stance at the party conference in Brighton EPA Brexit and climate protests at Labour party conference: In pictures Activists from anti-climate change movement Extinction Rebellion march on the Labour conference in Brighton AFP/Getty Brexit and climate protests at Labour party conference: In pictures Delegates take part in an informal vote on Labour's Brexitr stance at the party conference in Brighton AFP/Getty Brexit and climate protests at Labour party conference: In pictures Shadow foreign secretary Emily Thornberry leads a march in support of a second referendum on Brexit Getty Brexit and climate protests at Labour party conference: In pictures Anti-Brexit protesters take part in a People's Vote rally during the Labour party conference in Brighton EPA Brexit and climate protests at Labour party conference: In pictures Extinction RebelliActivists from anti-climate change movement Extinction Rebellion march on the Labour conference in Brightonon EPA Brexit and climate protests at Labour party conference: In pictures Extinction Rebellion activists march on the Labour conference in Brighton AFP/Getty Brexit and climate protests at Labour party conference: In pictures A delegate arrives carrying a briefing from the Labour Representation Committee to the Labour party conference in Brighton Getty Brexit and climate protests at Labour party conference: In pictures Prominent anti-Brexit campaigner Steve Bray protests on Brighton beach during the Labour party conference Reuters Brexit and climate protests at Labour party conference: In pictures Anti-Brexit protesters take part in a People's Vote rally during the Labour party conference in Brighton EPA Brexit and climate protests at Labour party conference: In pictures Activists raise a banner calling for the Labour party to restore the original Clause 4 of its constitution, which would pledge the party to nationalising all industry Getty

“Within parliament itself there is a large number of people who are saying we’d rather have a referendum attached to any deal,” he acknowledged.

And he added: “Once we get to the stage of blocking no deal, a general election is on the table. If we can’t get that general election, the referendum becomes an option.”

The Independent revealed yesterday that Labour MPs are bombarding the party whips’ office with demands for Mr Corbyn to back a referendum first.

In the interview, Mr McDonnell also:

* Ruled out a coalition deal with the Scottish National Party, or the Liberal Democrats, if Labour falls short of a majority – insisting Mr Corbyn would put forward his programme and challenge the other parties to vote it down.

* Denied Mr Corbyn had been “dragged kicking and screaming” into supporting a Final Say public vote, saying: “He hasn’t. You’re wrong on this.”

* Argued “climate change is the big issue now”, which meant the election would be “more than a class revolution”.

* Denied Labour at Westminster was riven by splits, insisting: “I’ve never seen the parliamentary Labour Party more united in the last couple of years.”

* Suggested Boris Johnson is as extreme as Donald Trump, saying: “I think it is very difficult to see anything between them.”

* Described his 70-year-old leader’s fitness as “unbelievable”, saying: “He’s running every morning. Jeremy is the fittest person I know.”

* Admitted the attempt to remove Tom Watson as deputy leader, on the eve of Labour’s conference last month, had been “a fiasco” – but insisted Mr Corbyn “wasn’t aware” of it in advance.

On Labour’s election chances, Mr McDonnell denied the poll ratings – putting Labour in the low twenties – meant “the country has just decided Jeremy is not going to be prime minister”.

He insisted Mr Johnson “has got vulnerabilities just as much as Theresa May that we can expose and exploit in a campaign”.