Iceland's leading right-of-center Independence Party, led by Prime Minister Bjarni Benediktsson, won the lion's share of votes - 25 percent - but could end up out of power as a center-left coalition appears to have secured an overall majority, albeit a slim one.

The Left-Green Movement finished second with 17 percent, and could end up leading the next government. The Greens, along with the Social Democrats, the Progressive Party and the Pirate Party have secured a razor thin majority in parliament - winning 32 mandates in the 63-seat chamber.

Typically the president tasks the leader of the party that won the most votes with trying to form the next government, which would be Benediktsson, who leads the Independence Party. But given that he has no clear path to forming a new government President Gudni Johannesson could task the head of the Greens with forming the next Cabinet.

Green Party members and their supporters react with cautious optimism after the first results came in Saturday night

Johannesson has not said yet what he will do. Should he bypass Benediktsson, the task of forming a new government would likely fall to 41-year-old Katrin Jakobsdottir - the leader of the Greens and a former education minister.

Prime Minister Benediktsson called the snap election six weeks ago, after a junior coalition partner quit the nine-month-old government.

It's Iceland's second snap election in a year. The centrist Bright Future Party accused Benediktsson of a "serious breach of trust" following allegations that the prime minister tried to cover up his father's role in clearing the record of a convicted pedophile.

Read more: Small currency, big worry: Iceland's volatile krona

Prime Minister Benediktsson and his Independence Party won the most votes but could find themselves out of power

At least six parties are expected to cross the 5-percent threshold needed to enter the 63-seat parliament, but as many as eight parties could end up in parliament. That makes it a virtual certainty that a coalition government will have to be formed. Given the ideological divisions, the talks could be protracted.

The left's shot at power

Ahead of the vote, Prime Minister Benediktsson's right-of-center Independence Party was running slightly ahead of the Left-Green Movement, which is led by former Education Minister Katrin Jakobsdottir. But the Social Democratic Alliance was polling a strong third and the anti-establishment Pirate Party was also showing well, giving left-of-center parties their best shot at governing in some time.

Katrin Jakobsdottir of the Left-Green Movement casting her vote

If the projections hold, it would be "a call for the opposition to form a government," said the 41-year-old Jakobsdottir, in an interview with the Morgunbladid newspaper.

Results of the snap election are due on Sunday.

Iceland election: in brief

About 248,000 voters eligible to vote

Polling stations close at 2200 UTC

At least six parties expected to enter the 63-seat parliament

Opinion polls suggest no outright winner

PM Benediktsson's Independence Party poised to be the largest party

A coalition led by Left-Green Movement's Katrin Jakobsdottir may form a government

The previous snap election took place late in 2016 following the resignation of then Prime Minister Sigmundur David Gunnlaugsson amid a scandal over offshore accounts revealed in the Panama Papers leaks.

bik, ap/jm (AFP, AP, dpa, Reuters)