Scott Morrison has become Australia's new prime minister after Malcolm Turnbull was forced out by party rivals in a bruising leadership contest.
Mr Turnbull had been under pressure from poor polling and what he described as an "insurgency" by conservative MPs.
Mr Morrison, the treasurer, won an internal ballot 45-40 over former Home Affairs Minister Peter Dutton - who had been Mr Turnbull's most vocal threat.
Mr Turnbull is the fourth Australian PM in a decade to be ousted by colleagues.
"It has been such a privilege to be the leader of this great nation. I love Australia. I love Australians," he said on Friday.
With an election looming, MPs were nervous about the government's poor opinion polling and recent by-election defeats.
Last week, a row over energy policy ignited long-existing tensions between Mr Turnbull, a moderate, and his party's conservative wing.
Mr Dutton, a conservative, then unsuccessfully challenged Mr Turnbull on Tuesday, but his narrow defeat only stoked further discord.
Mr Morrison entered the race after Mr Turnbull lost key backers. After a majority of MPs called for a leadership "spill", Mr Turnbull agreed to step down.
To further complicate matters, Mr Turnbull has signalled he would resign from parliament, which would force a by-election and potentially put the government's one-seat majority at risk and force the new premier to call early elections.
However, Mr Morrison, who was sworn in on Friday, told reporters there were no plans to do this any time soon.
His government, he said, would be in place by next week.
Who is Morrison?
Mr Morrison, a former Tourism Australia official, entered parliament in 2007 and has since held three key ministerial portfolios.
A social conservative who appeals to the moderate elements of the Liberal party
Rose to national prominence as immigration minister in Tony Abbott's government
Built a reputation as a tough operator in enforcing Australia's hardline "stop the boats" policy
Drew criticism over the controversial asylum seeker policies and offshore detention centres
Seen as a pragmatic, ambitious politician who has long eyed the top job
The 50-year old father-of-two is a leading religious conservative and opposed last year's same-sex marriage bill.
Speaking to reporters after the vote on Friday, Mr Morrison said he would be working to "bring our party back together which has been bruised and battered this week" and bring the country together.
He also said dealing with a severe drought, which has hit parts of eastern Australia, would be "our most urgent and pressing need right now".
How has everyone reacted?
With a mixture of bemusement, anger and sheer frustration: many have described this week as one of the most chaotic in Australian political history.
In his final press briefing, Mr Turnbull called the week "madness" and thanked his colleagues for choosing Mr Morrison over Mr Dutton.
"We have so much going for us in this country. We have to be proud of it and cherish it," he said.
Mr Dutton said: "My course from here is to provide absolute loyalty to Scott Morrison, and make sure we win the election."
Foreign Minister Julie Bishop was also in the running for the leadership, but did not make it to the final round.