Both Shopify (NYSE:SHOP) and PayPal (NASDAQ:PYPL) have provided dazzling returns to investors in recent years, with their shares soaring 524% and 133%, respectively, since Shopify's IPO in May 2015.

But which of their stocks is the better buy today? Let's find out.

A compass pointing towards the word "growth."

Shopify and PayPal are two of the best growth stocks available in the market today. We put them head-to-head to see which is likely to outperform in the coming years. Image source: Getty Images.

The business case for PayPal

As the owner of Venmo, Xoom, and its namesake payments platform, PayPal is well-positioned to profit from the global trend toward digital payments and away from cash transactions.

PayPal added 7.7 million new customer accounts in the second quarter of 2018, bringing its total to more than 244 million active accounts. The company processed 2.3 billion payment transactions for those customers -- a 28% year-over-year increase -- totaling $139 billion in total payment volume.

Yet despite the tremendous scale it has already achieved, PayPal still has long runways for growth ahead of it. The company believes it can compete and win in large and rapidly growing businesses such as mobile payments, business lending, and merchant services. Based on its track record, I think the company's ambition is well-placed. In turn, PayPal -- and its shareholders -- have many ways to win in the years ahead. 

The business case for Shopify

Shopify's e-commerce platform gives businesses of all sizes the opportunity to build and grow their online operations. It's a massive market that the company has only just begun to tap. In fact, Shopify's management estimates that there are approximately 46 million small- and medium-sized businesses that could potentially benefit from its services. Yet despite a torrid growth rate that has brought its customer base to 600,000 today, Shopify has penetrated less than 2% of its total addressable market.

Over the years, the company has steadily expanded its offerings, which now include credit card processing, shipping, and lending services, among others. Its platform and tools also smoothly integrate with a wide variety of third-party apps. Together, they give entrepreneurs most of what they need to run their online businesses. And the more these businesses prosper, the more Shopify benefits: As its customers' sales grow, so too do the fees it collects on their transactions.

As such, Shopify has created a win-win situation for itself and its customers -- one that should continue to serve it well for many years to come.

Comparing valuations

Metric

Shopify 

PayPal 

P/S

22.41

7.33

Forward P/E

271.44

30.20

PEG

10.00

1.96

Data sources: Yahoo! Finance. P/S = Price-to-sales. P/E = Price-to-earnings. PEG = Price-to-earnings growth.

Looking at this chart, one thing rapidly becomes clear: Shopify stock is priced at a premium based on traditional valuation ratios.

PayPal's shares are far cheaper in terms of both price-to-sales and price-to-earnings. Thus, investors who buy PayPal's stock are paying less for each dollar of sales and earnings than they are when buying Shopify. This is somewhat to be expected, as Shopify is growing much faster than PayPal. Analysts expect Shopify's earnings per share to rise by an incredible 100% annually over the next half-decade, compared to the less than 20% annualized growth forecast for PayPal during that same period.

But even if we account for Shopify's higher projected earnings growth rate -- as we do with the forward price-to-earnings-to-growth (PEG) ratio -- PayPal's shares are still the better deal.

The better buy is...

PayPal and Shopify are both high-quality businesses with outstanding growth prospects. But with its shares currently trading at a far more attractive valuation, PayPal is the better buy for investors today.

Joe Tenebruso has no position in any of the stocks mentioned. The Motley Fool owns shares of and recommends PayPal Holdings and Shopify. The Motley Fool has a disclosure policy.