Sweden’s parliament has backed a no-confidence vote in the centre-left prime minister, Stefan Löfven, making him the first premier to be ousted by opposition MPs in the country’s history and giving him a week to resign or call snap elections.

The vote, called by the nationalist Sweden Democrats barely a year before a general election, plunges Sweden back into political uncertainty four years after the last inconclusive poll produced a deadlocked parliament and led to months of negotiations to form a coalition.

Löfven’s fragile minority Social Democrat-Green coalition has been propped up by tacit support from two small centre-right parties and the formerly communist Left party, which withdrew its backing over plans to ease rent controls on new apartments.

The motion, voted on by all 349 MPs despite Covid restrictions, needed 175 votes to pass and got 181. The Sweden Democrat leader, Jimmie Åkesson, told parliament the government was historically weak and “should never have come to power”.

The Left party blamed the prime minister for the crisis, with its leader, Nooshi Dadgostar, saying the Social Democrat-led government had “given up on the Left party and the Swedish people”, rather than the other way round.

Last-ditch efforts by the Social Democrats to appease the Left party, which has 27 MPs, over the weekend proved in vain, with the party insisting the government’s plans to overhaul rent controls, potentially opening the door for landlords to freely set rents for new-build apartments, ran counter to Sweden’s social model.

Three scenarios now look possible: Löfven could resign, leaving the parliamentary speaker with the job of finding a new majority; a snap election could be called, even though the 2022 poll must proceed as planned; or a political compromise could allow the government to stay on in a caretaker capacity.