Kevin Rudd staged a comeback on Wednesday after he ousted Prime Minister Julia Gillard as head of Australia's ruling Labor Party in a leadership ballot, three years after he was deposed by her in party coup.
Rudd, 55, was elected after Gillard called a ballot in a television interview following media reports that supporters of Rudd were circulating a caucus petition to allow a challenge for the prime ministership.
Former prime minister Rudd, who was ousted by Gillard three years ago, won 57 to 45 Labor caucus votes.
The development came ahead of September 14 general elections, which surveys suggest Labor is set to lose.
It is unclear whether Rudd will stick to Gillard's schedule of the September election or go for an earlier one. The earliest date Rudd can call an election for is August 3.
The result may spell the end of 51-year-old Gillard's political career, with Australia's first female prime minister declaring earlier today that she would not stand in the next election if she lost the ballot.
It is also expected that several cabinet ministers including School Education Minister Peter Garrett will now quit the frontbench, as they have previously said they would do so if Rudd was re-elected.
Ahead of the vote, Rudd said tens of thousands of "ordinary Australians" have been asking him to take back the leadership.