They've been bitter rivals, allies and colleagues.
Clinton's chances of winning the White House hinge on rallying Obama's coalition to her cause. Obama's legacy depends on her success. Eight years after they spent millions tearing each other down in pursuit of the White House, they will now spend countless words and four months selling each other to the public.
The foe-to-friend story will be at the center of the Obama-Clinton show in Charlotte, North Carolina, aides to both say. In his remarks, the president will act as a character witness for his former secretary of state, who is struggling to convince voters of her trustworthiness and honesty. There is no better politician to testify on her behalf, many Democrats believe, than the man who once counted himself among the Clinton skeptics but came around to be one of her biggest boosters.
"I think that he can be very helpful, particularly with Democratic voters and some independent voters who have doubts," said David Axelrod, the chief architect of Obama's 2008 race for the Democratic nomination against Clinton. "He can do that by sharing his own experience. They were rivals, they had their differences; that gives him some additional standing."
The Clinton campaign also is hoping Obama acts as a reminder of another, more popular chapter in Clinton's career. For four years, Obama trusted her to circle the globe representing his foreign policy to the world. She sat at his side in the Situation Room. She was the good soldier, putting aside her political ego to join the administration of the man who defeated her. During her tenure at the State Department she was viewed favorably by most Americans.
The White House confirmed Monday that Clinton and Obama will travel to the event together on Air Force One. The last time they traveled together was 2012 when they visited newly democratic Myanmar, a particular issue of interest to Clinton. While Obama and Clinton are only expected to be in Charlotte for a few hours, their schedules leave room for a possible unannounced stop around town that could showcase their rapport.
"As someone who was a former rival and came to put a lot of faith in her, we believe the president's support for her is particularly meaningful to voters," said Clinton campaign adviser Jennifer Palmieri.
Clinton's Republican presidential rival objected to the travel plan. "Why is President Obama allowed to use Air Force One on the campaign trail with Crooked Hillary?" Donald Trump tweeted. "Who pays?"
Presidents make all their airplane flights on Air Force One, no matter the purpose of the trip. Political committees are required to contribute to the cost of a president's campaign-related travel, though a portion of such costs is borne by taxpayers, too.
"As in other Administrations, we follow all rules and regulations to ensure that the DNC or other relevant political committee pays what is required for the President to travel to political events," the White House said in a statement.
Clinton campaign spokesman Nick Merrill said: "As is the standard practice, the campaign will cover its portion of the costs."
Obama makes his first campaign appearance during a wave of popularity unlike anything he's experienced since his first term. Clinton aides say they're confident they could deploy him in any battleground state, though they believe he'll be particularly effective rallying young people, as well as black and Hispanic voters, and will be instrumental in voter registration efforts.
Obama won't just fire up these voters' Clinton kudos, of course. In a series of remarks in recent weeks, the president has proven himself to be one of the Democrats' most effective critics of Trump. From his perch at the White House and on the world stage, Obama has regularly found ways to blast Trump's message and mock his style. The mix of high-minded concern and sharp-elbowed sarcasm is widely viewed as an effective, tweetable model for other Democrats.
Still Obama won't spend the next four months as the "Trump-troller in chief," as one official put it. Obama plans to take a largely positive message on the road as his campaigning picks up later this summer. That's in part because he's campaigning for the continuation of his agenda — as well as Clinton's. On health care, immigration, financial reform and the environment, Clinton is largely promising a continuation or acceleration of Obama's policies.
Obama and Clinton originally planned to make their first campaign appearance together in Wisconsin, a Democratic-leaning state where Clinton struggled in her primary fight with Bernie Sanders. Campaign aides viewed the rally as a way to forge Democratic unity after the bruising primary and consolidate the party's voters in a state Clinton needs to carry in November.
But the June 15 rally was postponed due to the mass shooting at an Orlando nightclub. By the time the campaign and White House got around to rescheduling, Clinton aides said the landscape had shifted — they are now far less worried about bringing along Bernie Sanders voters and more interested in using the president to rallying voters in one of the most divided general election battlegrounds.
Obama narrowly won North Carolina in the 2008 presidential election, becoming the first Democrat to win the state since 1976. His campaign aggressively registered more young people and black voters, and he drew support from moderates in the booming suburbs of Charlotte and Raleigh-Durham.
The president was eager to cement Democrats' strength in North Carolina during his re-election campaign, even holding his convention in Charlotte. But he was dogged by a sluggish economy and disappointment among some swing voters, and lost to Republican Mitt Romney by 2 percentage points.