President Biden is taking criticism for placing Marines behind him during a deeply partisan speech Thursday evening outside Independence Hall in Philadelphia despite promising in 2020 he would not use the military as a "prop."

Biden was criticized by some commentators and veterans groups for having Marines behind him during a speech in which he took aim at "MAGA Republicans" and claimed that "equality and democracy are under assault."

In 2020, then-candidate Biden told the National Guard he would never put them in the middle of a political dispute and that he would restore respect to civilian-military relations.

"But I promise you as president, I'll never put you in the middle of politics or personal vendettas," he said. "I'll never use the military as a prop or as a private militia to violate the rights of fellow citizens. That’s not law and order. You don't deserve that."

BIDEN SLAMMED BY VETERANS GROUP FOR USING MARINES AS ‘PROPS’ IN PARTISAN SPEECH 

Biden speech Marines

President Biden, protected by bulletproof glass, delivers remarks on what he calls the "continued battle for the soul of the nation" in front of Independence Hall in Philadelphia Sept. 1, 2022.  (REUTERS/Jonathan Ernst)

At that time, Democrats criticized then-President Trump for using armed forces for political reasons, including deploying them to the U.S.-Mexico border. Biden said Trump denied the National Guard necessary resources when he diverted funding to build a border wall.

CNN ANCHOR HITS BIDEN FOR HAVING MARINES BEHIND HIM AT ANTI-MAGA SPEECH: MILITARY IS SUPPOSED TO BE APOLITICAL

But Biden was similarly accused of using the military as a prop Thursday, after Marines stood behind him as he railed against "Donald Trump and the MAGA Republicans," who Biden said "represent an extremism that threatens the foundation of our republic."

Despite White House claims that it was not a campaign speech, Biden urged viewers to "speak out, get engaged [and] vote, vote, vote!" He also touted legislation he had signed on climate, infrastructure and economic stimulus.

BIDEN UNSETTLES MARINE BAND MEMBERS BY CAMPAIGNING FOR DEMOCRATS AT EVENT WHERE THEY PLAYED

"When elected officials use our troops as props in political and partisan messaging, it undermines the nonpartisan nature of our military and erodes trust in the institution," John Byrnes, Concerned Veterans for America director and U.S. Marine Corps veteran, told Fox News Digital Friday.

A White House official told Fox Biden "gave an important speech last night about our democracy and our values, values that our men and women in uniform fight every day to protect.

John Byrnes

John Byrnes is a Marine Corps and Army National Guard veteran who served combat tours in Somalia, Iraq and Afghanistan. He serves as education director for Concerned Veterans for America.

"The presence of Marines at the speech was intended to demonstrate the deep and abiding respect the president has for their service to these ideals and the unique role our independent military plays in defending our democracy, no matter which party is in power," the official continued.

CLICK HERE TO GET THE FOX NEWS APP

Meanwhile, government watchdogs raised questions about the use of the Marines. Kendra Arnold, executive director of the Foundation for Accountability and Civic Trust, told Fox News Digital that, generally speaking, "there is a separation between official government communications and overtly political communications."

"This both protects taxpayer funds and the public’s confidence that our government is not a political entity," Arnold said. "Also, given that they were prominently visible behind the president, I would add that the military should never be used for partisan political purposes."