Sweden's parliament on Wednesday voted to reinstate Social Democrat party leader Stefan Lofven as prime minister, only weeks after he was ousted in a historic vote of no confidence.
Lofven's nomination was passed with a vote of 116 for, 173 against and 60 abstaining.
Under the Swedish system a prime minister can be confirmed as long as a majority does not vote against them.
"Since less than half of the members of parliament have voted no, the chamber has approved the motion to appoint Stefan Lofven as prime minister," Speaker Andreas Norlen told parliament.
Lofven later told a press conference hee was "shouldering the task with determination and respect".
"Parliament has given me the confidence to continue to lead Sweden," he said.
To get the vote passed, Lofven's Social Democrats secured a deal with the centre-right Centre Party, which agreed to abstain from voting against him, clearing the way for his confirmation.
Still, the margin was razor thin and on Tuesday the Social Democrats even struck a separate deal to secure the support of individual independent member of parliament Amineh Kakabaveh, formerly of the Left Party, as a single vote could have tipped the balance.
- Housing row -
An "unholy alliance" of parties, from the Left Party to the far-right Sweden Democrats, teamed up to oust Lofven's coalition government -- made up of the Social Democrats and the Greens -- on June 21.
Following the confidence vote, Lofven had the option to either call a snap election or resign, which he chose to do on June 28 -- leaving it up to the speaker of parliament to start looking for a successor.
The confidence motion was filed by the Sweden Democrats after the Left Party, which had been unhappy with a plan to ease rent controls for newly built homes.
Lofven had agreed to the policy to secure the support of two other centre-left parties for his minority government, as part of a drawn-out struggle to find a workable coalition following inconclusive elections in 2018.
But the Left Party and other critics see any easing of the rent controls as fundamentally at odds with the Swedish social model, and a threat to tenants' rights.
- 'Ready to blow' -
Despite being crucial in the vote to topple Lofven's government, the Left Party supported his return, with party leader Nooshi Dadgostar noting that now the "issue of market rents is not on the table."
Even with his swift return, Lofven's might soon be facing his next political crisis as he now takes office without a deal to secure passing a budget this autumn.
"His method has been one step at a time, he has first acted to get re-elected, then he'll take on the budget," Ulf Bjereld, a professor of political science at the University of Gothenburg, told AFP.
In declaring their voting intentions, several opposition parties criticised Lofven's return, especially as his government now be on even shakier footing, and some even declared that a snap election would have been preferable -- even if it would be one in addition to the scheduled general election in September 2022, which will go ahead regardless.
Christian Democrat leader Ebba Busch said the government would now be a "ticking bomb".
"Ready to blow up and throw us into another crisis already this autumn and then it would be better to let voters have their say."
After being appointed in Sweden, the prime minister should announce their cabinet "as soon as possible," and then the new government formally takes office during a ceremony with the head of state, currently King Carl XVI.