WASHINGTON >> Faced with a sweeping rejection by American voters, Kamala Harris conceded the presidential election to Donald Trump on Wednesday and encouraged supporters to continue fighting for their vision of the country.

The Democratic vice president said the battle would continue “in the voting booth, in the courts and in the public square.”

“Sometimes the fight takes a while,” she said at Howard University, her alma mater, where she had hoped to make a victory speech after the election. “That doesn’t mean we won’t win.”

Harris’ decisive defeat shattered hopes that she could rescue Democrats’ chances after President Joe Biden’s reelection effort stalled and she replaced him at the top of the ticket.

She trailed in every battleground state to Trump, a Republican whom she described as an existential danger to the country’s foundational institutions. And Trump appeared on track to win the popular vote for the first time in his three campaigns for the White House — even after two impeachments, felony convictions and his attempt to overturn his previous election loss.

Despite her stark warnings about Trump, Harris reached for optimism on Wednesday.

“It is OK to feel sad and disappointed, but please know it’s going to be OK,” she told supporters as some of them wiped tears from their eyes.

Biden released a statement praising Harris after her speech, saying: “She will continue the fight with purpose, determination, and joy. She will continue to be a champion for all Americans. Above all, she will continue to be a leader our children will look up to for generations to come as she puts her stamp on America’s future.”

Minnesota Gov. Tim Walz, Harris’ running mate, was in the audience with his family. So were Reps. Nancy Pelosi, the former House speaker, and Barbara Lee, both from Harris’ home state of California.

Before her speech, Harris called Trump to congratulate him on his victory. She told the crowd that “we will engage in a peaceful transfer of power,” an implicit reference to Trump’s unwillingness to do the same four years ago.

After Trump lost to Biden, he directed his supporters to march on the U.S. Capitol, leading to a violent insurrection that interrupted the ceremonial certification of the election results.

Now Harris is expected to oversee the same certification process to finalize Trump’s victory as voters brush off concerns about the future of American democracy and return the former Republican president to the White House.