Poland election earthquake: What happens next?

Getty Images Malgorzata Kidawa-Blonska, member of Civic Platform smiles during the election night after the announcement of election results.Getty Images
A politician from Civic Coalition - one of the opposition parties with the numbers to form a majority - grins after the exit poll

A second exit poll in Poland has predicted the governing right-wing populist Law and Justice party won the most votes in Sunday's election but will lose its majority in parliament.

If the official result, expected on Tuesday, confirms the second exit poll prediction - which has a 2% margin of error - it's up to President Andrzej Duda, a former Law and Justice MP, to appoint a new prime minister to form a government.

Who gets first shot at forming a government?

It's customary - and President Duda has said he would do this - for the president to choose the leader of the largest single party, in this case Law and Justice, to have the first shot at forming a government and securing a vote of confidence in parliament.

However, Law and Justice appears to have no clear route to forming a government with a majority, whilst a diverse opposition coalition of Civic Coalition, the Third Way and the Left does seem able to form a government with a majority.

According to the second exit poll, Law and Justice would win 198 seats, well short of the 231 needed for a majority. Its potential coalition partners are limited as even with the far-right Confederation party, they would muster only 212.

The opposition could count on 248 seats.

If President Duda lets Law and Justice have the first go and it fails, then parliament gets the second shot at forming a government, which if the result confirms the exit polls, would give a majority to the opposition coalition.

President Duda could also decline to ask Law and Justice to try to form a government given the parliamentary maths.

What if nothing is agreed?

If that second parliamentary attempt fails, then President Duda selects another candidate for PM, and if that fails, he can call fresh elections.

If all these stages pan out, Poland could be without a government into November and December - and/or heading towards fresh elections.

What do the opposition parties disagree on?

If the opposition coalition is appointed and confirmed in a vote of confidence, it will not have an easy time.

Firstly, it's politically diverse, from the moderate conservatives of the Third Way to some hard-left MPs in the Left.

For example, both Civic Coalition and the Left support liberalisation of the rules on abortion. Civic Coalition and the Left campaigned to allow women to choose to terminate their pregnancies up to 12 weeks.

The Third Way takes a more conservative approach, saying it wants to overturn a 2020 court ruling outlawing abortion in cases of severe foetal defects - which effectively banned all legal pregnancy terminations - but would then put the issue of any further steps to a referendum.

The Left wants to significantly reduce the influence of the Catholic Church on state institutions, something that Third Way MPs may be uncomfortable with.

What obstacles could a coalition face?

The opposition block has pledged to restore the independence of the judiciary and the public media.

The European Commission and multiple international bodies say Law and Justice's reforms have undermined judicial independence and media pluralism. Under Law and Justice, the state media has been transformed into party (Law and Justice) media.

But again, such change could face opposition from two important actors - President Duda, and Poland's top court the Constitutional Tribunal, which is now controlled by judges who are sympathetic to Law and Justice.

Both have the power to veto an opposition government's legislation.

An opposition coalition would not have the three-fifths majority in parliament required to overturn a presidential veto, so President Duda could make life difficult for them.