The updated Ipsos survey showed Nawrocki with 50.7 percent of the vote, ahead of centrist rival Rafał Trzaskowski, who had 49.3 percent.
An initial exit poll, conducted for broadcasters TVP, TVN and Polsat and released just after voting ended at 9 p.m., had projected a Trzaskowski win.
Ipsos said its updated "late poll" combined exit poll data with partial official returns from 90 percent of voting stations and had a margin of error of up to 0.5 percentage points.
Official results are expected later on Monday.
After the initial projection pointed to his victory, Trzaskowski told supporters he was ahead by a "razor's edge."
Rafał Trzaskowski with wife Małgorzata. Photo: PAP/Paweł Supernak
He thanked voters and all those who backed him in the race, pledging to "connect and build" if confirmed as the country's next president.
"This is a special moment in Poland’s history, and I am convinced it will help us all move forward like a torpedo, to focus primarily on the future," he told the crowd.
"I will truly be the president of all Poles; I will be your president," he declared.
Nawrocki, meanwhile, urged his supporters to wait for the official results.
Karol Nawrocki votes at a polling station in Warsaw on Sunday, accompanied by his family. Photo: PAP/Paweł Supernak
“We will win and save Poland," he vowed.
"We have to win tonight—and we know we will," he added, as updated projections and vote counts were expected later in the night.
If confirmed by the National Electoral Commission (PKW), Nawrocki's win could pose new challenges to the pro-European government of Prime Minister Donald Tusk.
Trzaskowski, 53, a senior politician of Tusk's ruling Civic Coalition (KO), campaigned on a platform of strengthening Poland’s ties with the bloc and advancing judicial reforms.
Nawrocki, a conservative historian backed by the opposition Law and Justice (PiS) party, had pledged to veto liberal reforms, promote traditional Catholic values and align Poland more closely with Donald Trump's America.
The close race highlighted deep divisions in Polish society over the country’s direction, with the president holding significant veto power over legislation.
The election saw high voter turnout, with 71.7 percent of eligible voters casting ballots, according to the updated exit poll.
In the first round of voting on May 18, no candidate won an outright majority, meaning a second round had to be held.
The Polish president is the head of state and has the power to veto legislation passed by parliament, a key prerogative in a country where traditionalists and liberals are bitterly divided.