It's official: We've entered a new bull market. The S&P 500 (^GSPC 1.02%) reached a new all-time high last week, and it's currently up by nearly 36% from its low point in October 2022.

If you've been holding off on investing, now could be the perfect time to dive back in. While there are no guarantees that stock prices will keep rising, if you wait too long to buy, you could miss the early stages of this bull market.

It's critical, though, to ensure you're investing in the right places. Whether you're new to investing or simply want a low-fuss investment that's extremely likely to make money over time, there's one index fund to buy hand over fist right now: the S&P 500 index fund.

The right index fund for your portfolio

An S&P 500 index fund is an investment that tracks the S&P 500 index itself. It includes the same stocks as the index and aims to mirror its performance over time.

The S&P 500 includes stocks from 500 of the largest and strongest companies in the U.S. across a wide variety of industries. By investing in just one index fund, then, you'll own a stake in every single stock in the index. That can create an instantly diversified portfolio with next to no effort on your part.

This type of investment is also among the safest and most reliable out there. The S&P 500 has a decadeslong track record of recovering from periods of volatility, so no matter what the future holds for the market, an S&P 500 index fund is likely to recover.

^SPX Chart

^SPX data by YCharts

In fact, research shows that as long as you keep a long-term outlook, it's nearly impossible to lose money with this investment. Analysts at Crestmont Research examined the S&P 500's long-term performance, and they found that every single 20-year period in the index's history ended in positive total returns.

In other words, if you had invested in an S&P 500 index fund at any point in history and simply held it for 20 years, you'd have made money -- regardless of how volatile the market was in that time.

Building wealth in the stock market

Despite its relative safety, an S&P 500 index fund can also help you generate a substantial amount of wealth over time.

Historically, the market itself has earned an average annual return of around 10% per year. This means that while you likely won't earn 10% returns every single year, the annual returns have averaged out to roughly 10% per year over decades.

If you're earning a 10% average annual return and investing, say, $200 per month, here's approximately how your savings might add up over time:

Number of Years Total Portfolio Value
20 $137,000
25 $236,000
30 $395,000
35 $650,000
40 $1,062,000

Data source: Author's calculations via investor.gov.

Keeping a long-term outlook is key when investing in the stock market, and the more time you can give your money to grow, the more you can potentially earn. If you haven't started investing yet, now is the perfect time to begin.

Choosing the right S&P 500 index fund

Most S&P 500 index funds are similar, as they track the same index and contain identical stocks. But three of the most popular options include the Vanguard 500 Index Fund Admiral Shares (VFIAX -0.46%), Schwab S&P 500 Index Fund (SWPPX -0.46%), and Fidelity 500 Index Fund (FXAIX -0.46%).

Each of these index funds charges low fees, making them a more affordable way to invest. The Fidelity fund has an expense ratio of just 0.015%, while Schwab sits slightly higher at 0.02%, and Vanguard's is at 0.04%. In other words, you'd pay $1.50, $2, or $4 per year in fees for every $10,000 in your account, respectively.

There's no single correct way to invest, but an S&P 500 index fund can be a low-cost, low-effort way to build wealth in the stock market. By investing as much as you can afford and giving your money as much time as possible to grow, you could potentially earn hundreds of thousands of dollars (or more) over time.