The current bull market nearly came to an end in April. The S&P 500 (SNPINDEX: ^GSPC) crashed 19% lower at the start of the month after President Donald Trump announced much higher-than-expected tariff rates. Stocks quickly recovered when the President walked back some of the most severe tariffs and delayed others. And the market hasn't looked back since.
Just over six months later, the S&P 500 is up over 40% from its intraday low in early April. The Nasdaq Composite (NASDAQINDEX: ^IXIC) is up nearly 57%. And both closed at record high levels on Friday, Oct. 24.
After such a strong run in the market, investors may be worried about putting more of their hard-earned cash to work in stocks. Growing signs of economic weakness and tons of uncertainty around trade policies might make it feel as if the next bear market could start any minute. After all, every bear market begins, by definition, when stocks are trading at an all-time high.
But history is quite clear on whether it's a smart idea to buy stocks when the S&P 500 hits an all-time high.
All-time highs usually lead to new all-time highs
To be scared out of investing in stocks because they trade at or near an all-time high goes against rational expectations. Overall, investors expect stocks to go up in the long run. If that's the case, then the expectation should be that they're priced higher tomorrow than they are today, all else being equal. In other words, an all-time high is the base assumption when you buy something like an index fund.

SNPINDEX: ^GSPC
Key Data Points
Granted, that's not how things work in practice, where market forces like investor behavior have a much bigger impact on day-to-day stock prices than underlying fundamentals. But investors are, by their nature, generally optimistic, so there's a bias for stocks to move higher over time unless something especially noteworthy happens to disrupt earnings growth and cash flows.
As a result, one all-time high usually leads to many more all-time highs in quick succession. In fact, since reaching a new all-time high in January of 2024, the S&P 500 has closed at a new all-time high 90 more times in the last 21 months. If you had invested in an S&P 500 index fund when stocks first reached an all-time high in 2024, you'd have seen your investment increase more than 40%.

NASDAQINDEX: ^IXIC
Key Data Points
Momentum is an especially strong market force. The average inflation-adjusted returns for U.S. large-cap stocks one year after reaching an all-time high are 10.4%. By comparison, the one-year average return for investing at any other time is just 8.8%, according to an analysis by Schroders.
That said, investment returns tend to even out over the long run. The 36-month return is the same for investing at an all-time high or any other time. That speaks to the market's tendency to revert to the mean. However, if you keep cash on the sidelines, you could easily miss out on the big gains that make up for any future dips in the market.
The adage "time in the market beats timing the market" is absolutely true. And with relatively equal long-term return expectations, it doesn't pay to wait for prices to fall. Famous fund manager Peter Lynch put it best. "Far more money has been lost by investors in preparing for corrections, or anticipating corrections, than has been lost in the corrections themselves."
How to invest when stocks are at an all-time high
As stocks increase in price, it becomes a lot more difficult to find shares trading for compelling values.
This bull market is especially tough to navigate. Valuations have climbed across the board, and the S&P 500 as a group trades for a forward P/E of about 22.4, well above its historic average in the mid-teens. Carefully considering the underlying business of a stock, assessing its potential growth, and determining its fair value could still reveal some bargains, though.
But if you don't have the time or inclination to study individual companies, an S&P 500 index fund is a great option. After all, history is on your side.
One of the best options is the Vanguard S&P 500 ETF (VOO +0.13%). The ETF charges an extremely low expense ratio of just 0.03% and it has a great record of tracking the index closely.

NYSEMKT: VOO
Key Data Points
Importantly, there's no need to dollar-cost average if you have a lump sum you've been saving while waiting for stocks to go back down. On average, dollar-cost averaging leaves investment gains on the table, which makes sense given that stocks increase in value over the long run. If it makes you feel more comfortable, though, dollar-cost averaging is better than not investing at all.
While stocks look expensive right now, trying to time the market is impractical and often a losing endeavor.