Both men hold appeal among independent voters – about a third of the electorate – and whoever wins a majority of them wins in November. So while both candidates must hold onto the bulk of their party regulars, they will also play to the nonideological center in a way that the nominees didn't in the last two presidential races.
Still, for McCain, the anti-Republican headwind he faces cannot be underestimated.
In any analysis of the 2008 race, "you start with the already-well-described Democratic advantage this time around, beginning with unhappiness over the war and the economy," says Bruce Buchanan, a political scientist at the University of Texas, Austin.
President Bush's abysmal job approval ratings also don't do McCain any favors. Even if Bush were doing reasonably well, history would still point toward a Democrat in 2008. Rarely is a two-term president succeeded by the nominee of his own party.
Generic polls show Americans preferring, with no names attached, a Democratic president to a Republican by a double-digit margin.
But McCain's image of independence and working across the aisle gives him a shot in November. So far, he is holding his own in polls versus Obama.
One of the great unknowns is the race factor. With no historical precedents for a nonwhite nominee, it is impossible to predict how or where Obama's race will affect his chances.
While McCain faced some grumbling among key GOP constituencies when he locked up the party nomination – particularly among movement conservatives and evangelical voters – Obama, too, must unify his party after a divisive primary season. He will need the support of the working class, older, and Hispanic voters that flocked to Hillary Rodham Clinton, and thus how she ends her candidacy and whether she works hard for Obama's election loom large over Obama's chances.