Polish President Andrzej Duda is set for a tight run-off against Warsaw's liberal mayor next month after Sunday's inconclusive first-round vote, leaving the fate of the populist right-wing government in the balance.

Duda, who is backed by the governing Law and Justice (PiS) party, is expected to come out on top in the first-round vote with 41.8 percent, according to an exit poll by Ipsos.

Rafal Trzaskowski, who has promised to heal rifts with the European Union, is set to come second with 30.4 percent, but could receive endorsements from other opposition candidates ahead of the July 12 second round of voting.

Polish President Andrzej Duda is a key ally for the government
Polish President Andrzej Duda is a key ally for the government AFP / Wojtek RADWANSKI

"I will be the candidate of change!" Trzaskowski said at an election night party in a redeveloped former power station in Warsaw.

Trzaskowski, who is also 48 and is from the Civic Platform (PO) party, appealed to voters "who want an open Poland, not a Poland always looking for enemies".

The election was scheduled to be held in May but had to be postponed because of the coronavirus pandemic.

AFP / Vincent LEFAI

Voters came out in large numbers despite contagion fears, waiting in socially distanced queues outside polling stations and casting ballots in their masks and visors.

Turnout was high compared to previous votes at 62.9 percent, the exit poll said.

Warsaw mayor Rafal Trzaskowski is expected to go head-to-head with the incumbent President Andrzej Duda in a run-off vote
Warsaw mayor Rafal Trzaskowski is expected to go head-to-head with the incumbent President Andrzej Duda in a run-off vote AFP / JANEK SKARZYNSKI

Duda is seen as a key ally by Donald Trump and received the US president's blessing when he visited the White House earlier this week, the first foreign leader to do so since the pandemic began.

But he has raised hackles in Brussels by endorsing a controversial reform of the judiciary that critics say is eroding democracy -- three decades on from the end of communist rule in Poland.

Experts were divided on who could win the election next month.

Polish President Andrzej Duda's policies have raised hackles in the EU
Polish President Andrzej Duda's policies have raised hackles in the EU AFP / BARTOSZ SIEDLIK

Kazimierz Kik, professor of political science at the Jan Kochanowski University in Kielce in south central Poland, said he believed Duda had "greater potential" than Trzaskowski to mobilise voters who stayed at home on Sunday.

But Stanislaw Mocek, head of the Collegium Civitas University in Warsaw, said Trzaskowski had a "good chance" of winning in the second round.

Mocek also warned of the risk of a "brutal campaign" if Duda attempts to appeal to far-right voters, whose candidate is also expected to have scored well in Sunday's vote.

"This is a decisive time. A lot will really depend on this decision," anti-communist icon Lech Walesa said as he cast his vote in the northern port of Gdansk wearing a transparent plastic visor over his face.

The Polish election was delayed from May because of the coronavirus pandemic
The Polish election was delayed from May because of the coronavirus pandemic AFP / Wojtek RADWANSKI

Walesa, who was elected Poland's first democratic president in 1990, has been a trenchant critic of the current government.

The campaign was dominated by concerns over an erosion of democratic rights and bread and butter economic issues. Poland faces its first recession since the end of communism because of the pandemic fallout.

"I voted for Trzaskowski of course! Why? For democracy, the judiciary and respect for minorities," said Joanna Ugniewska, 66, after casting her ballot at a polling station in a school in Warsaw city centre.

But in Tarnow in southern Poland, a PiS stronghold, Andrzej Guzik said he would be voting for Duda because of his consistent leadership.

"Personally I only see Duda as president," said Guzik, 52, an employee at the PGNIG state gas company.

Poland's government has implemented popular social welfare payments in recent years, which Trzaskowski has promised to retain if he wins.

Victory for Duda would cement the party's hold on power -- at least until the next scheduled parliamentary elections in 2023.

But defeat could see its influence unravel and trigger early elections.

During the campaign, Duda stoked controversy by echoing PiS attacks on gay rights and Western values.

He likened "LGBT ideology" to a new form of communism.

Trzaskowski, however, supports gay rights and says he is open to the idea of same-sex civil partnerships.

But critics say his party is weak and ineffectual and that his record as mayor is mixed.