Mr Livingstone kept fighting until polls closed
Labour's Ken Livingstone has lost his bid to win a third term as London's mayor.
His defeat to Tory challenger Boris Johnson was another dramatic moment in a career that has already seen its fair share of ups and downs.
From public vilification as a "loony left" pariah within his own party, to elder statesman and Britain's most powerful directly-elected politician, Mr Livingstone has refused to be written off.
Begins his political career aged 26 when he is elected to Lambeth Borough Council in 1971.
Ousts the moderate Labour group leader Andrew McIntosh after the party takes control of the Greater London Council in May 1981. As head of the authority, Mr Livingstone commands a multi-billion pound budget and is one of Prime Minister Margaret Thatcher's most high-profile opponents.
The congestion charge was Mr Livingstone's most high-profile policy
Boosts use of public transport in the capital with his low-cost London Underground "Fares Fair" policy.
Crosses the Thames from County Hall to the House of Commons as MP for Brent East in 1987.
Runs as an independent against the official Labour candidate for London mayor, Frank Dobson, in 2000, staging a spectacular victory.
Introduces the Congestion Charge, despite fierce opposition from the motorists' lobby, in 2003. In 2007 the zone nearly doubles in size thanks to the western extension.
Also in 2003, brings in Oyster cards - rechargeable travel cards for commuters.
Is welcomed back into the Labour fold in 2004. Then-Prime Minister Tony Blair, who previously warned Mr Livingstone would be a "disaster", admits his prediction "has not turned out to be right".
Wins a second term in City Hall the same year.
In 2005, celebrates the International Olympic Committee's decision to award London the 2012 games.
Condemned as an extremist by the tabloids and "the most odious man in Britain" by the Sun, for his support for left-wing causes as GLC leader. Later argues that his decision to back gay rights and meet Sinn Fein's leaders puts him 20 years ahead of the political game.
Loses his political powerbase in 1986 when the GLC is abolished.
Condemned to backbench obscurity after his election to Westminster by Labour leaders who believe his left-wing views make him an electoral liability.
Mr Livingstone's meeting with Gerry Adams in 1983 was hugely controversial
Despite winning more votes from individual party members, loses the battle for the Labour nomination for London mayor to Frank Dobson in 1999. Temporarily cast out of the party fold when he stands - and wins - as an independent.
Suspended from office for four weeks in 2006 for comparing a Jewish journalist to a concentration camp guard, a move that he described as "anti-democratic" and which was later overruled by a High Court judge.
At the outset of the 2008 mayoral campaign, faces revelations that he fathered five children by three different women.
Faces scandals involving his advisers. Rosemary Emodi resigns after the BBC discovers she lied about taking a free weekend in Nigeria, while Lee Jasper is forced out following reports about his private life.
During the 2008 campaign, Mr Livingstone said he would retire from front-line politics if he lost, to write his memoirs and spend more time with his family.
But with such a proven capacity for comebacks, most Livingstone watchers would advise against dismissing his chances of yet another resurgence.