Andersson was selected to replace Stefan Lofven as party leader and prime minister, roles he resigned earlier this year.
In a speech to parliament, Amineh Kakabaveh, an independent lawmaker who supported Andersson, noted that Sweden is currently celebrating the 100th anniversary of a decision to introduce universal and equal suffrage in the Scandinavian country.
“If women are only allowed to vote but are never elected to the highest office, democracy is not complete,” said Kakabaveh, who is of Iranian Kurdish descent.
“There is something symbolic in this decision,” she added. “Feminism is always about girls and women being complete people who have the same opportunities as men and boys.”
“I was really moved by what she said. She pointed out exactly what I was thinking,” Andersson said after her appointment to parliament, where she received a standing ovation and a bouquet of red roses.
“I have been elected Sweden’s first female prime minister and know what it means for girls in our country,” Andersson said.
In the Riksdag with 349 seats, 117 legislators voted yes to Andersson, 174 rejected her appointment, while 57 abstained and one legislator was absent.
According to the Swedish constitution, prime ministers can be appointed and governed as long as a parliamentary majority – a minimum of 175 legislators – is not against them.
Lofven has led the Swedish government as caretaker until a new government is formed, something that is expected on Friday. Andersson is likely to form a two-party minority government with his Social Democrats and the Green Party.
Andersson, 54, sought to secure support from the two smaller parties that supported Sweden’s former center-left-minority government led by Lofven – Venstrepartiet and Centerpartiet. Both abstained from voting against Andersson.
After days of negotiations, Andersson and the Left Party reached an agreement to win the latter’s support. The deal focused on pensions, meaning a supplement of up to $ 1,000 ($ 152) for about 700,000 low-income retirees.
Sweden’s next parliamentary election is scheduled for 11 September.