President Barack Obama has endorsed presumptive Democratic presidential nominee Hillary Clinton, signaling he will fight to ensure that she succeeds him in the White House.

Obama made his endorsement via a video released Thursday:

"I want to congratulate Hillary Clinton on making history as the presumptive Democratic nominee for the president of the United States," Obama said in the video.

"I don't think there's ever been someone so qualified to hold this office," he said, adding, "I want those of you who've been with me from the beginning of this incredible journey to be the first to know that I'm with her."

Sen. Bernie Sanders (I-Vt.) met with Obama at the White House earlier in the day, and said afterward during a press conference that he would work to ensure presumptive Republican presidential nominee Donald Trump does not make it to the White House. Sanders did not endorse Clinton or say that he would withdraw from the race.

Obama mentioned Sanders in his endorsement of Clinton, thanking the senator for "shining a spotlight on issues like economic inequality and the outsized influence of money in our politics, and bringing young people into the process."

Obama emphasized that Clinton and Sanders have a shared vision of "the values that make America great."

"Those are the values that are going to be tested in this election," he said.

Clinton thanked Obama for his endorsement in a tweet:

Honored to have you with me, @POTUS. I'm fired up and ready to go! -H — Hillary Clinton (@HillaryClinton) June 9, 2016

Trump reacted to Obama's endorsement in a tweet Thursday:

Obama just endorsed Crooked Hillary. He wants four more years of Obama—but nobody else does! — Donald J. Trump (@realDonaldTrump) June 9, 2016

Clinton quickly responded to his criticism with a tweet of her own:

Clinton became the presumptive nominee on Monday, exceeding the 2,383 delegates required to be the party's choice on the November ballot, according to The Associated Press. She declared victory Tuesday evening, after winning primary contests in four states and earning a majority of pledged delegates in the race.

Obama has hinted for months that he would endorse Clinton, but said it would be inappropriate to wade into the campaign until she clinched the nomination.

He is set to campaign with Clinton in Green Bay, Wisconsin, on June 15.

Bloomberg via Getty Images

White House aides have said Obama is eager to defend Clinton against Trump. Obama has already begun assailing the former reality television star, sprinkling barbs against him into his recent speeches.

Clinton, who served as Obama's secretary of state, is probably better equipped to preserve Obama's presidential legacy than Sanders. Clinton aligned herself with Obama's policies during the campaign, citing this as a reason primary voters should choose her over Sanders. Obama, referring to Clinton, acknowledged that "on certain issues, she agrees with me more than Bernie does."

Obama has said he respects Sanders and his progressive platform. But in recent months, as Sanders' odds of winning grew longer, the president has hinted that the Vermont senator should cede the race to Clinton and allow the party to unite around her.

Former Maryland Gov. Martin O'Malley, who competed against both Sanders and Clinton in the Democratic presidential primary, gave his endorsement shortly after Obama backed the former Secretary of State.

"For the future of the country we carry in our hearts, I am committing my energies to the election of Secretary Clinton as the next President of the United States," O'Malley said in a statement. "Democrats, Independents and Republicans alike must come together to confront the fascist threat to our democracy presented by Donald Trump. The stakes in this election could not be higher, and the choice is clear."

ASSOCIATED PRESS President Barack Obama and then Secretary of State Hillary Clinton on a trip to Myanmar in 2012.

In February, Obama emphasized the importance of compromise and pragmatism in politics and warned against ideological absolutism.

"When I hear voices in either party boast of their refusal to compromise as an accomplishment in and of itself, I’m not impressed,” Obama said. “All that does is prevent what most Americans would consider actual accomplishments, like fixing roads, educating kids, passing budgets, cleaning our environment, making our streets safe."

Clinton and Obama fought a bruising presidential primary battle in 2008, but mended ties. After conceding the race, Clinton campaigned for Obama in the general election. Obama offered her the secretary of state position, which she accepted after some hesitation. The two eventually developed a working partnership.

Clinton often spoke on the campaign trail of how she put aside her differences with Obama to work in his administration.

"Obviously, I'm excited about having the president's support," she said Monday. "I have said throughout this campaign I was honored to serve in the president's cabinet as his secretary of state."