STOCKHOLM (AP) — Sweden’s parliament on Monday elected conservative leader Ulf Kristersson as prime minister at the head of a center-right coalition that has promised to crack down on crime and curtail immigration in partnership with a populist party with far-right roots.

Kristersson, 58, was elected in a 176-173 vote and will present his government on Tuesday.

His three-party coalition secured a majority in the 349-seat Riksdag, or parliament, after the Sept. 11 election by teaming up with the Sweden Democrats, a party founded by right-extremists in the 1980s. The party has softened its image and moved toward the mainstream, but was until recently considered too radical to work with by all other parliamentary groups.

Kristersson presented a deal last week whereby his conservative Moderate Party will form a government with the smaller Christian Democrats and Liberals, while coordinating government policies closely with the Sweden Democrats, which won 20% of the vote to become Sweden’s second-biggest party.

They agreed on a common platform that included making it harder for asylum-seekers to stay in Sweden and easier for authorities to deport foreign nationals with links to criminal gangs. Gang violence has become a major concern in Sweden, particularly in neighborhoods dominated by immigrants, and is considered a key reason for the country’s shift to the right.

“It feels great, I am grateful,” Kristersson told reporters in Stockholm after the vote. “I am happy about the trust that I have received from the Riksdag. I am also humbled by the tasks that lie ahead of us.”

Kristersson, who has led the Moderates since 2017, will take over the prime minister’s post from Magdalena Andersson, the leader of the center-left Social Democrats, which are now in opposition after eight years in power.

The Social Democrats and other opposition parties have criticized the incoming coalition for opening the door to the Sweden Democrats. Nooshi Dadgostar, the leader of the former communist Left Party, said her parents who fled from Iran could never have imagined that Sweden would embark on an authoritarian path.

“What is happening now in Sweden is frightening,” she told parliament before the vote.

Since the election, the Sweden Democrats have landed the chairmanships of four parliamentary committees, giving it the ability to wield more influence.

In addition to immigration and criminal justice, the incoming coalition has agreed to work with the Sweden Democrats on other areas such as energy, including efforts to expand nuclear power.

The change in government isn’t expected to affect Sweden’s historic bid to join NATO with neighboring Finland, which was endorsed by a clear majority in parliament following Russia’s invasion of Ukraine on Feb. 24.

___ Jan M. Olsen contributed to this report from Copenhagen, Denmark.

___

This story has been corrected to show that Kristersson’s age is 58, not 59.