Amazon (AMZN 1.91%) has come a long way since starting out as an online book retailer in 1994. After branching out to digital music and videos in 1998, the company has gone on to become an e-commerce titan and a dominating force in the cloud market with Amazon Web Services (AWS), and has expanded to many other industries. 

In 2022, the company's stock plunged almost 50% on account of macroeconomic headwinds detrimental to its e-commerce business. However, Amazon has retained significant long-term growth despite the sell-off. 

So an investment even just a decade ago would have yielded substantial gains for patient investors. Here's how much you would have accumulated if you had invested $10,000 in Amazon's stock in 2013.

Stellar long-term growth 

From 2014 to 2022, e-commerce sales rose over 320% from a value of $1.34 billion to $5.72 billion, with the market projected to hit $8.15 billion by 2026. Meanwhile, Amazon's revenue has risen by 741% in the last 10 years to $513.98 billion, and operating income has increased 1,700% to $12.25 billion.  

The rise of digital shopping drove much of Amazon's growth over the years, with the e-commerce giant leading the U.S. market share at 37.8% by June 2022. In comparison, the second-largest market share went to Walmart with 6.3%.

Amazon's e-commerce business stumbled amid economic declines in 2022, with its related segments reporting combined operating losses of $10.5 billion in the year. However, the industry is projected to continue expanding at a compound annual growth rate (CAGR) of 14.7% through 2027, with Amazon likely to profit significantly along the way. 

Moreover, Amazon's best move over the years has been the launch of its cloud platform AWS. The service was responsible for 100% of Amazon's $12.2 billion in operating income in 2022, after a 28.7% year-over-year rise in revenue of $80 billion. AWS holds a leading 34% market share in the cloud industry, a lucrative position considering the market is expected to grow at a CAGR of 14.1% through 2030, according to Grand View Research.

Amazon shares have soared 612% in the last 10 years alongside its immense success, even taking into account the sell-off in 2022. As a result, those who bought $10,000 worth of Amazon's stock in January 2013 would have $78,138.51 today, with an annual rate of return of 22.42%. The growth proves the importance of holding stocks over the long term, as doing so can safeguard your investment against short-term headwinds. 

Should you invest in Amazon stock?

Amazon has clearly provided investors with substantial growth in the last 10 years. However, deciding whether now is the best time to invest is a bit more complex. 

After a year plagued with declines, Amazon started 2023 at a disadvantage. Compared to the competition, its free cash flow plunged throughout 2022, as seen in the chart below.

Chart showing Amazon's free cash flow falling significantly since 2020, compared to other major tech stocks.

Data by YCharts.

The deep valley in Amazon's free cash flow over the last year illustrates how the company's business was far more vulnerable to economic declines than its peers. Its steep financial decline over the last year has led its price-to-earnings ratio (P/E) to soar 66% and made it far higher than the competition. Take a look below.

Chart showing Amazon's price-to-earnings ratio much higher than those of several other major tech companies in 2022.

Data by YCharts.

Among the biggest names in tech, Amazon's P/E is the only one to have risen over the last year, while the other companies have seen the same metric decline as their stocks have increased in value. 

Amazon likely has a long and fruitful future ahead. It is a leader in two high-growth markets, and its impressive development over the last decade makes its stock a good investment to hold for many years. However, right now, more attractive options are available, such as the other companies displayed in the charts above. Therefore, it's best to invest your money elsewhere for now and keep an eye on Amazon's stock to buy at the right time.