Stocks rallied after the initial COVID-19 sell-off in March 2020 as government stimulus fueled consumer spending and induced robust economic growth worldwide. But since the start of 2022, the stock market has turned into a circus show. Between 40-year-high inflation, the Federal Reserve's decision to hike interest rates in return, and adverse impacts linked to Russia's invasion of Ukraine, investor sentiment is being pummeled from multiple directions.

Year-to-date, the S&P 500 and Nasdaq Composite have contracted 22% and 33%, respectively, and now there are legitimate fears that a recession is on the horizon. Technology stocks have been particularly fragile, and that includes e-commerce companies, which continue to combat unfriendly macro conditions combined with a reopening economy.

As long-term investors, however, it's vital that we don't lose sight of the endgame. Global digital commerce is projected to expand at a compound annual growth rate (CAGR) of 15.1% to $17.5 trillion by 2030, up from $4.2 trillion today. So while investors must distinguish between the secular winners and losers, it has never been so clear that e-business is the future.

This e-commerce top dog has collapsed 78% year to date, offering canny investors a golden buying opportunity today.

Person online shopping on cellphone.

Image source: Getty Images.

Adjusting to the new landscape

Shopify (SHOP 1.11%) posted an undesirable first-quarter report to kick off 2022. Total sales finished largely in line with Wall Street expectations, growing 21.7% year over year to $1.2 billion, but adjusted earnings per share drastically missed estimates, falling 90% year over year to $0.20.

During the earnings call, management continually emphasized that massive changes in the macro landscape -- like high inflation and the reopening of the global economy -- adversely impacted the company's business in Q1. This shouldn't shock investors, however. COVID expedited the shift to e-commerce and government stimulus made it more accessible to pay for Shopify's services.

Even so, gross merchandise volume (GMV) increased 15.8% year over year to $43.2 billion, and monthly recurring revenue (MRR) climbed 17% to $105.2 million. It surely wasn't an ideal quarter for the e-commerce leader, but these aren't bad year-over-year growth rates when considering Q1 2021, which marked the highest quarterly revenue growth in company history.

Besides Amazon, Shopify reigns over the largest share of U.S. retail e-commerce sales, representing 10.3% of the overall market. In terms of e-commerce software, the company takes the cake for largest market share, controlling nearly one-third of the industry. With more than one million merchants in its network worldwide and an estimated addressable market of $160 billion, Shopify is in good hands moving forward.

For the company's fiscal 2022, Wall Street analysts expect total sales to surge 28.9% year over year to $7.5 billion, and adjusted earnings per share is projected to retreat a walloping 84% to $1.30. Next year, which is when adverse comparable metrics will normalize, analysts estimate revenue to soar 29.6% to $9.7 billion and earnings per share to bounce back 98% to $2.57.

While you should take these forecasts with a grain of salt, for now, the point is that a sound recovery is likely in Shopify's future. Today, the stock trades at eight times sales, and while that may seem expensive, it's Shopify's lowest price-to-sales multiple in five years. In my opinion, with its strong market positioning and weakening valuation, now is a great time to accumulate shares of the e-commerce stock. 

Time to go against the grain

Taking the road less traveled often leads to incredible investments in the long run. Today, many investors have fallen out of love with Shopify, which leads me to believe now is an optimal buying moment. Once short-term headwinds standardize, all signs point to continued success for the e-commerce company in the future.

It's the No. 1 platform merchants visit to build online businesses, a secular trend that will only be amplified in the years to follow -- not to mention, the stock is trading at its lowest valuation in five years, adding yet another layer of security for investors.