President Donald Trump's low-profile appearance Sunday night at Game 5 of the World Series came at a high-profile moment of his presidency - yet he still drew loud boos and chants of 'lock him up'.

Wearing a dark suit and a tie, Trump arrived at Nationals Park just before the first pitch of the Houston Astros-Washington Nationals match-up.

Hours earlier, he had announced that U.S. forces had hit the hiding place of Islamic State leader Abu Bakr al-Baghdadi, who was killed in the raid in northeast Syria.

A military success against a most-wanted enemy of the U.S. and its allies could have provided the president a rare moment of bipartisan comity, especially amid a divisive impeachment inquiry, but the crowd had other plans.

Scroll down for video

President Donald Trump's low-profile appearance Sunday night at Game 5 of the World Series came at a high-profile moment of his presidency - yet he still drew loud boos and chants of 'lock him up'

A military success against a most-wanted enemy of the U.S. and its allies could have provided the president a rare moment of bipartisan comity, especially amid a divisive impeachment inquiry, but the crowd had other plans

Video from the stadium captured Trump's beaming smile drop suddenly to a grimace when he heard the boos echo out

Trump and First Lady Melania Trump entered a lower-tier box to the left of home plate as the game got underway.

At that point his presence wasn't formally announced, but baseball fans in the section just below Trump's suite turned to look toward the box as he arrived. Some waved at the president as he smiled and gave a thumbs-up.

At the end of the third inning, ballpark video screens carried a salute to U.S. service members that drew cheers throughout the stadium.

When the video cut to Trump and his entourage, cheers abruptly turned into a torrent of boos and heckling, with chants of 'Lock him up!" breaking out in some sections.

Footage captured by NBC moments after the stadium announcer called out his name documented Trump's beaming smile drop sharply to a grimace when he first heard the boos ring out.

Trump then appeared to shake off the hostile reception, reclaiming his smile and waving enthusiastically to the crowd.

But the taunts continued throughout the game, with two fans behind the home plate unfurling signs that read 'VETERANS FOR IMPEACHMENT' at one stage.

It isn't initially clear if Trump, who left the game around 10pm, saw the banner on the stadium's display board before making his exit.

Trump appeared unfazed and continued waving. Later, some fans behind home plate held a sign reading 'VETERANS FOR IMPEACHMENT'

Until Sunday night, Trump had yet to attend a major league game as president even though the White House is a few miles northwest of Nationals Park (pictured: President Donald Trump, accompanied by first lady Melania Trump, left)

The taunts continued throughout the game, with two fans behind the home plate unfurling signs that read 'VETERANS FOR IMPEACHMENT' at one stage

Another banner captured by a spectator shows the words 'Impeach Trump' on a banner, with white text overlayed on an orange background

Until Sunday night, Trump had yet to attend a major league game as president even though the White House is a few miles northwest of Nationals Park. He's been known in the past to support both the New York Yankees and the Mets.

A dozen or so congressional lawmakers accompanied the president, according to a list provided by the White House, including Sens. Lindsey Graham of South Carolina and David Perdue Georgia.

'I think everybody is excited,' Nationals star pitcher Stephen Strasburg said before the game. 'It's the president of the United States. So there's obviously beefed-up security. So usually the dogs that are sniffing in our clubhouse are these nice Labs that are super friendly. And today there was a German shepherd that I didn't really feel comfortable petting.'

Nationals manager Dave Martinez said: 'He's coming to the game. He's a fan. Hopefully he cheers for the Washington Nationals, and I hope he enjoys the game.'

Trump's staff has long tried to shield him from events where he might be loudly booed or heckled, and he has rarely ventured into the neighborhoods of the heavily Democratic city. He won just over four percent of the vote in the District of Columbia in 2016.

WATCH: President Trump met with loud boos as he is introduced at the World Series in Nationals Park on Sunday night. pic.twitter.com/4RTW8ZqxqP — NBC News (@NBCNews) October 28, 2019

Trump's staff has long tried to shield him from events where he might be loudly booed or heckled, and he has rarely ventured into the neighborhoods of the heavily Democratic city. He won just over four percent of the vote in the District of Columbia in 2016

Trump's staff has long tried to shield him from events where he might be loudly booed or heckled, and he has rarely ventured into the neighborhoods of the heavily Democratic city. He won just over four percent of the vote in the District of Columbia in 2016

Major League Baseball Commissioner Rob Manfred said he discussed with Trump whether he'd like to throw out the ceremonial first pitch, but the president declined while citing the disruption that would cause fans getting to the ballpark.

Washington Nationals principal owner Mark Lerner told the Washington Post that Trump should be at the game, but he made clear that he did not invite Trump to throw out the first pitch, saying there were many other candidates that should be considered before Trump.

Jose Andrés, a prominent local restaurant owner and humanitarian, threw out the first pitch to a roaring, sustained ovation. He has a history with Trump, too, both in business and in politics.

Andrés has repeatedly opposed Trump's immigration policies and his administration's response to Hurricane Maria in Puerto Rico.

Four years ago, he withdrew from plans to open a restaurant in the Trump International Hotel in Washington following Trump's controversial comments about Mexican immigrants during the presidential campaign. Legal action ensued and the dispute was settled in 2017.

A home run from Yordan Alvarez in the second inning put the Astros up 2-0 on the Nationals early in a pivotal Game 5 of the World Series, which is now tied at 2-2

Hours earlier, Donald Trump beamed with pride in a press conference when he announced that ISIS leader Abu Bakr al-Baghdadi had died after deploying his suicide vest as U.S. Special Ops forces raided his hideaway on Saturday night in Idlib, northwest Syria

President Trump was booed loudly by the fans at Nats Park when he was shown on the big screen.

Then came a loud chant: “Lock him up.” @wusa9 pic.twitter.com/LBbgSAHd6k — Adam Longo (@adamlongoTV) October 28, 2019

Hours earlier, Donald Trump beamed with pride in a press conference when he announced that ISIS leader Abu Bakr al-Baghdadi had died after deploying his suicide vest as U.S. Special Ops forces raided his hideaway on Saturday night in Idlib, northwest Syria.

Trump touted the news as a giant triumph for his administration and boasted it was even more profound than the Obama administration's military strike against al-Qaeda leader Osama bin Laden.

‘Last night the United States brought the world’s number one terrorist leader to justice, Abu Bakr al-Baghdadi is dead,’ Trump declared. ‘He was the founder and leader of ISIS, the most ruthless and violent terror organization anywhere in the world.

'The thug who tried so hard to intimidate others spent his last moments in utter fear, in total panic and dread, terrified of the American forces bearing down on him.'

Al-Baghdadi's words inspired more than 140 terrorist attacks in 29 countries other than Iraq and Syria, resulting in the deaths of at least 2,043 people.

The raid was launched around midnight Sunday morning, with Trump watching a feed of the strike from the White House Situation Room.

In the operation eight American helicopters, mostly CH-47 Chinooks, took off from a military base near Erbil, Iraq.

The helicopters then flew low and fast to avoid detection, and were subjected to sporadic ground fire, in the perilous 70-minute flight. Once they arrived to their destination they released a hail of gunfire on a compound of buildings as a cover for commandos with the Delta Force and their military dogs.

The U.S. military operation to strike ISIS leader Abu Bakr al-Baghdadi was a success despite actions by President Donald Trump, according to military, intelligence and counterterrorism officials

Al-Baghdadi (above) was tracked down following the arrest and interrogation of one of his wives and a courier this past summer, but the plans to strike his compound were jeopardized when Trump announced he would pull American troops out of Syria

The commandos then dismounted at al-Baghdadi's compound, blowing up one of its walls which allowed them to rush in. Once inside they confronted a group of ISIS fighters.

The Delta Force officers entered the compound where they shot and killed a number of people and removed 11 children from area.

Fearing capture al-Baghdadi ran into an underground tunnel taking three of his children with him while American troops were on his tail. Fearing he was armed with a suicide vest, which he was, the troops sent a military dog after him.

In the tunnel the Islamic State leader detonated his suicide vest, wounding the dog and killing the three kids.

The entire raid lasted around two hours, and involved just shy of 100 U.S. military personnel.

In Trump's description of the successful strike he said: 'I got to watch much of it. Al-Baghdadi died after running into a dead-end tunnel, whimpering and crying and screaming all the way.'

'He died like a dog,' Trump added.

After clearing out, American warplanes bombed the compound to assure it was physically destroyed.