Ed Miliband has quit as Labour leader after a dramatic election night where his party was virtually wiped out in Scotland and David Cameron was on the way to a Commons majority.

Reflecting on the devastating results after 30 seconds of applause, Mr Miliband said he took "absolute and total responsibility" for the result, offering apologies to big Labour beasts including Ed Balls and Jim Murphy who were defeated overnight.

He added: "Britain needs a strong Labour Party, Britain needs a Labour Party that can rebuild after this debate so we can have a government that stands up for working people again.

"And now it is time for someone else to take forward the leadership of this party. So I am tendering my resignation, taking effect after this afternoon's commemoration of VE Day at the Cenotaph.

"I want to do so straight away because the party needs to have an open and honest debate about the right way forward, without constraint."

Rather than breaking through as forecast by opinion polls, Labour saw losses to the Tories in key marginal seats and failed to win the Conservatives most vulnerable constituencies.

Mr Miliband paid a fulsome tribute to Harriet Harman, who will take over as leader during the coming election contest, as the "best deputy leader anyone could hope for".

And he said: "We have come back before and this party will come back again."

Mr Miliband addressed an audience of noisy and passionate activists at a Westminster venue.

He told them he was looking forward to spending more time with his family and he thanked the British people for their involvement in his campaign.

"Thank you for the selfies, thank you for the support," he said.

"And thank you for the most unlikely cult of the 21st century - Milifandom."

To Labour voters he added: "While we may have lost the election, the argument of our campaign will not go away. The issue of our unequal country will not go away.

"This is the issue of our time, the fight goes on and, whoever is our new leader, I know Labour will keep making the case for a country that works for working people once again."

Mr Miliband said everyone "must rise to the challenge of keeping our country" in the wake of massive gains for the SNP.

Speaking in the wake of the defeat, f ormer Labour adviser Damian McBride told Sky News: "You can't have a scale of defeat like this and not go. What is the argument you could carry on and do better next time around?

"There is such a mountain to climb now and if anything the hole is much deeper."