A coalition of right-wing parties is expected to win Sweden's parliamentary elections by a tiny majority.
The alliance includes the controversial Sweden Democrats party which received 20 percent of the vote and traces its political origins to Swedish Neo-Nazi groups.
The four-party group is expected to win 176 seats in parliament, against 173 for incumbent Prime Minister Magdalena Andersson's coalition government.
READ MORE
The life and times of Queen Elizabeth II
Global leaders pay tributes to UK monarch
Mid-Autumn Festival poetry
The result marks a shift in Sweden's historically progressive politics and the end of eight years in government for the ruling Social Democrat party.
While the result has not yet been formally declared, Prime Minister Andersson has already announced that she will step down to allow the opposition to form a government.
"It looks like the four right-wing parties have received 50 percent of the votes in the election, they have a one or two seat advantage," she said in a news conference. "It's a thin majority, but it is a majority. So tomorrow (Friday) I will therefore ask for my dismissal as prime minister and the responsibility for the process going forward will now be with the parliament."
It now falls to Ulf Kristersson, leader of Sweden's opposition Moderate party to form a government with the right-wing coalition of the Sweden Democrats, Liberals and Christian Democrats.
"In a week's time, I hope we're in the midst of discussing the next government's tasks. We have two weeks to go before the parliament opens again and I'm going to do everything I can to have a quick and smooth and very good negotiation" Kristersson said at a campaign event on Wednesday.
But unease remains about the Sweden Democrats. Alhough the party has moved away from its white supremacist heritage, its anti-immigration and eurosceptic positions remain an uncomfortable change in Swedish politics.
One of the party's MPs, Tobias Joachim Friden Andersson, was criticized during the campaign after he posted a photograph of a train, clad in the party's logo on twitter and wrote, "You have a one way ticket. Next stop: Kabul"- a clear attack on Sweden's progressive asylum seeker policies.
Even though they are now in position to influence the formation of the new coalition government, the Sweden Democrats still do not enjoy the full support of their partners, who have instead opted for Kristersson to lead the coalition and become Sweden's next Prime Minister.
The result is expected to be ratified in the coming days, a moment that will formalize a noticeable shift to the right in Swedish politics.