The speaker of parliament, Andreas Norlen, is expected to meet the leaders of the eight parties represented in parliament in the coming days to determine who is best placed to form the next government.
Norlen is widely expected to task Kristersson with the job, but the Alliance does not hold a majority in parliament and has so far ruled out any collaboration with the far-right anti-immigration Sweden Democrats.
Lofven’s left-wing bloc holds 144 seats in the new parliament, just one more than the four-party centre-right Alliance. The left-wing bloc is made up of the Social Democrats and the Greens, who have governed together with the informal support of the ex-communist Left Party since 2014.
The Social Democrats posted their worst election score in more than a century, but they remain Sweden’s biggest party, far ahead of Kristersson’s conservative Moderate Party and the Sweden Democrats.
Lofven will stay on as prime minister in a caretaker role until a new government is in place, which could take weeks.