The pandemic was a huge catalyst for shopping online. Global e-commerce sales jumped from $3.3 trillion in 2019 to $4.25 trillion in 2020. But don't think this is just a one-time boost -- the growth of e-commerce has been ongoing for many years and should continue for many more into the future. In fact, third-party analysts expect the global e-commerce industry to hit $7.4 trillion in annual spending in 2025. That's a 454% increase since 2014, when annual spending was only $1.33 trillion.

Here are three top stocks to buy right now that will benefit from long-term growth in e-commerce spending. 

Three people holding shopping bags looking at a phone.

Image source: Getty Images.

1. Revolve Group

Revolve Group (RVLV -0.21%)is an online fashion website focused on selling going-out clothes like dresses to younger women. It runs two websites: its flagship website Revolve.com and FWRD.com, a luxury website focused on selling more expensive items. The core products are dresses for events like festivals, weddings, and similar social occasions, but the websites also sell beauty products, shoes, and accessories.

Unlike most e-commerce companies, the pandemic was actually a huge headwind for Revolve Group as the world paused large social events. However, with the pandemic dwindling in the United States, Revolve Group is starting to see strong growth again. In the fourth quarter of 2021, revenue grew 70% year over year to $240 million, and net income grew 55% year over year to $29.4 million.

And this is before we head into music festival season, which is where Revolve does its heaviest marketing and ambassador campaigns. For example, at the largest U.S. music festival, Coachella, the company has its own side event called the Revolve Festival that features all its ambassadors and influencer partners. Once these come into full swing after a two-year pause, Revolve's growth could accelerate even further in the coming quarters.

Revolve stock trades at a market cap of $3.9 billion. In 2021, the company had a net income of approximately $100 million, giving the stock a price-to-earnings ratio (P/E) of 39. This looks expensive on a trailing basis, but if Revolve can continue growing its net income as we finally recover from the pandemic, its P/E will come down as well.

2. Coupang

Coupang (CPNG 2.04%) is a broad-based e-commerce and logistics company focused on the South Korean market. It runs a similar business model to how Amazon (AMZN 1.49%) works in the United States, with a selection of hundreds of thousands of products from third-party sellers, its own fulfillment and delivery network, and a fast-growing advertising business. With this vertically integrated model, the company has been able to rapidly gain market share in its home country, going from 7.4% in 2017 to 15.7% in 2021.

In 2021, Coupang's net revenue grew 54% to $18.4 billion, with active customers getting close to 18 million at the end of the year. On top of the core e-commerce business, Coupang is utilizing its delivery network to grow its grocery delivery and food delivery services. With all these ancillary products, it's no wonder that Coupang's revenue per active customer grew 11% year over year from $256 to $283 in the fourth quarter of 2021. This metric will be important for investors to track as a sign that Coupang is continuing to win market share in the South Korean market.

Right now, Coupang has a market cap of $32 billion. It is hard to value the business because it doesn't generate a profit or positive cash flow yet. However, management thinks that over the long term, its adjusted EBITDA margin can be between 7% and 10%, and gross margins can be between 27% and 32%.

Taking its $18.4 billion in revenue and applying a 7% profit margin, Coupang's profit would have been $1.3 billion last year. That translates to a P/E of 24.6, right around the market average. Given Coupang's rapid growth rate, this could mean the stock is a compelling investment opportunity right now -- if you think the projected 7%-plus profit margins are achievable.

3. Amazon

Lastly, we have Amazon, the original e-commerce business in the United States that has grown to a market cap of around $1.7 trillion. In 2021, the company generated $470 billion in revenue and $25 billion in operating income. At current prices, this gives the stock a price-to-operating-income ratio (P/OI) of 68.

So isn't Amazon stock expensive if it has a P/OI of 68? I would argue no. Similar to Coupang, Amazon has gone through a heavy investment cycle since the start of the pandemic to keep up with demand. This spending has impacted profits in the short term. But zooming in, investors can see that Amazon has built some highly profitable businesses that give it a strong competitive advantage and can help drive the stock over the next decade.

Amazon Web Services (AWS), the cloud computing division that is the backbone of the internet, generated $62.2 billion in revenue last year and $18.5 billion in operating income. This is up from only $17.5 billion in revenue in 2017. With the transition to cloud computing just starting, AWS should be able to continue this strong growth over the next decade, which is great news for Amazon shareholders.

Second, Amazon just broke out its advertising business, the core of which is sponsored listings on its website. Just in the fourth quarter of 2021, the advertising segment did $9.7 billion in revenue and was growing 33% year over year. We don't know how profitable the segment is, but looking at other advertising businesses, it likely has extremely high margins.

It is hard to value Amazon stock on one metric. But with the broad tailwind in e-commerce and the growth of both AWS and advertising, Amazon should be a solid investment over the next three to five years.