WASHINGTON (AP) — What could go possibly go wrong? (Or right?)

It’s the Labor Day question that keeps presidential candidates up at night.

Nine weeks from Election Day, the electoral math favors Democrat Hillary Clinton. But both Clinton and Republican rival Donald Trump know there are countless ways the trajectory of this uncommonly volatile presidential campaign still could shift in unexpected ways.

A health scare. An inopportune remark. A blockbuster debate. A WikiLeaks bombshell. A terrorist attack.

Even without a wildcard like Trump in the mix, history shows there’s no anticipating all the ways late developments can affect a race.

Just ask Mitt Romney: In September 2012, a secretly recorded video emerged that caught the Republican nominee saying 47 percent of Americans pay no taxes and consider themselves victims, feeding into impressions that Romney wasn’t looking out for ordinary people. In October, Hurricane Sandy roared up the East Coast, giving President Barack Obama a chance to showcase his commander-in-chief credentials and leaving Romney struggling to strike the right tone.

A classic October surprise: In 1972, as President Richard Nixon was fending off a challenge from Democratic Sen. George McGovern, Nixon authorized national security adviser Henry Kissinger to say “peace is at hand” in Vietnam. The late October pronouncement was welcome news to a war-fatigued nation, and bolstered Nixon’s re-election mandate. (It turned out Kissinger’s prediction was way off the mark: The heaviest bombing of the war started just before Christmas 1972.)

The 2000 campaign featured a November curveball: Word surfaced five days before the election that GOP nominee George W. Bush had been arrested on a misdemeanor drunken driving charge in 1976. Republicans said the release of 24-year-old information at such a time was a Democratic dirty trick, and a Democratic activist acknowledged he had tipped off reporters.

Bush won anyway, but many of his advisers still think the news depressed turnout among social conservatives to make the race much closer than it would have been otherwise, says Dan Schnur, director of the University of Southern California’s political institute and a veteran of John McCain’s 2000 presidential campaign.

In 2004, then-Sen. John Kerry headed into the final weekend of the campaign feeling good about his chances of ousting Bush. That’s when Osama bin Laden weighed in. Kerry believes the al-Qaida leader cost him the presidency by issuing a videotape that criticized Bush and warned U.S. voters that “your security is in your own hands” in the election.

“It changed the entire dynamic of the last five days,” Kerry said later. “We saw the polls freeze and then we saw them drop a point, because all the security moms, it agitated people over 9/11.”

More than a year after Trump and Clinton joined the race, a small but important chunk of voters is still up for grabs: An August Quinnipiac University poll found 4 percent of likely voters said they were undecided. And among those choosing a candidate, 9 percent said they still could change their minds.

For all of that, historians say it’s rare to see a race-altering late shift.

“Events happen, scandals take place, but usually the basic dynamics of the campaign are in place by then,” says Princeton historian Julian Zelizer. “If one person has a very big lead, then it’s hard to come back.”

Schnur’s advice on how Clinton and Trump can prepare just in case: “The best way to protect against an October surprise is to do smart planning in July, August and September.”