The stock market can be unnerving, especially during periods of volatility. With many Americans worried about a potential recession, it can be difficult to invest in times like these.

That said, the stock market is also a wealth-building powerhouse, and it's one of the easiest and most effective tools for making a lot of money over time.

While you don't necessarily need to be an investing expert or have thousands of dollars per month to become a millionaire, you will need the right strategy. Here's exactly how the stock market can transform $80 per week into $1 million or more.

Time is your most valuable resource

The earlier you begin investing, the easier it will be to accumulate a significant amount of money. Thanks to compound earnings, your investments will grow exponentially the longer they have to grow.

Person smiling and looking at a laptop.

Image source: Getty Images.

By getting started as early as possible in life, you'll need to invest less per week to reach your goal.

Historically, the S&P 500 index has earned an average rate of return of around 10% per year. This doesn't necessarily mean you'll earn 10% returns each and every year -- in fact, that's highly unlikely. Some years, you may not earn positive returns at all. Over decades, however, the annual highs and lows should average out to roughly 10% per year.

Assuming you're earning a 10% average annual return on your investments, here's approximately how much you'd need to invest each week to reach $1 million, depending on how many years you have to invest:

Number of Years Amount Invested per Week Total Savings
20 $375 $1.031 million
25 $225 $1.062 million
30 $130 $1.026 million
35 $80 $1.041 million
40 $50 $1.062 million

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

To reach $1 million with $80 per week, then, you'll need to invest consistently for around 35 years. But if you don't have that much time, investing more per week can help you reach your goal faster.

One major caveat to consider

It's also important to note that your investment returns will vary significantly based on where you invest.

If you're investing primarily in an S&P 500 tracking fund like an S&P 500 index fund or ETF, you'll likely earn average returns with minimal risk and effort. This type of investment is perfect for beginners or those who prefer a hands-off type of investment that doesn't require much maintenance.

On the other hand, if you're looking to beat the market and earn above-average returns, you may be better off investing in individual stocks. This strategy is more research-intensive than investing in an index fund or ETF, but there's also more potential for higher earnings.

Regardless of where you invest, though, the general principles remain the same: Significant growth takes time, so expect to leave your money in the market for at least several years or, ideally, decades.

Is it safe to invest right now?

Investing when the market is volatile is easier said than done, but again, time is your most valuable asset. If you wait for the perfect time to buy, you may need to invest more later to catch up.

For that reason, it's often best to simply invest consistently regardless of what the market is doing. This strategy is called dollar-cost averaging, and it involves investing routinely throughout the year. Sometimes, you'll invest when prices are lower. Other times, you'll buy when prices are high. Over time, though, those highs and lows should average out.

It's not always easy to invest in the stock market, but it can be an incredibly effective way to build long-term wealth. By choosing your investments wisely and investing consistently for decades, you can earn more than you might think.