Who will be the next U.S. president? In November we’ll know the answer. But regardless of who wins, stock market bulls have history on their side.

Dating back to 1952, the S&P 500 has booked an average gain of 7% during presidential election years. And while that’s not nearly as strong as the performance in the third year after an election (year three’s average gain is 17%), it’s still better than inflation.

Leading up to an election, it’s not uncommon for stock prices to undergo increased volatility. Uncertainty about the political outcome and the potential impact on economic policies are contributing factors to that.

Generally, the equity markets don’t like surprises or change. If the incumbent Democratic party wins this year, it could foreshadow policies that are consistent with the current ones. On the other hand, the new policies of an incoming Republican administration could spook investors if they augured radical changes. Still, as the financial markets absorbed the potential meaning of those changes, relative calm could follow.

In any case, it would be difficult for either party to derail the hot performance of stocks.

Through the first six months of 2024, exchange-traded funds linked to major indexes like the S&P 500 and Nasdaq-100 have delivered impressive results.

The SPDR S&P 500 ETF Trust (SPY) has spiked 15.69%, while the Invesco QQQ ETF has jumped 17.95%. Those performance figures are much better than the historical 7% average gain for the S&P 500.

The rally has been dominated by mega-cap stocks like Alphabet, Microsoft and Nvidia, which have pushed major equity indexes to all-time highs. Many of these stocks have soared on the craze surrounding artificial intelligence.

If there’s one potential weakness of the run-up, it’s the lack of participation by smaller mid- and small-cap stocks.

For 2024, the iShares Core S&P Small-Cap ETF (IJR) has declined 1.61%, while the SPDR S&P 400 MidCap ETF (MDY) has gained 5.79%. While neither performance return is bearish, the results still lag ETFs linked to large-cap stocks.

What are industry sectors saying about stock prices? Here, too, the message is overwhelmingly bullish.

Among the 11 sectors within the S&P 500, the Real Estate Select Sector SPDR Fund (XLRE) is the lone negative performer. And while the fund’s year-to-date fall of 3.22% looks awful against the broader S&P 500, it’s still a modest loss and far from uber-bearish.

Stocks from four S&P 500 industries—communication services, technology, energy and utilities—have scored double-digit gains. Moreover, with 10 sectors among 11 with positive gains, bullishness is widespread across various industry groups.

Regardless of who sits in the White House in 2025, stock prices favor bulls on two themes: stocks’ immediate price action … and history.