Cloud computing is changing how companies do business. Instead of purchasing expensive in-house computing resources that can quickly go out of date, companies can contract whatever computing power they need to entities like Amazon (AMZN 0.53%) Web Services (AWS), Microsoft (MSFT -1.33%) Azure, and Alphabet's (GOOG -2.99%) Google Cloud. Plus, this allows customers of these cloud operators to spend less money on IT teams that are dedicated to maintaining resources.

The use case of cloud computing is vast, which makes sense, given its current $447 billion market size. However, the cloud computing market is expected to grow to $1.6 trillion by 2030. Cloud computing is a massive investment opportunity, and investors need to pay attention to this space.

Which one of the big three is currently winning, and does it present a compelling investment case?

Who won in the most recent quarter?

All the major cloud providers recently reported quarterly results, so investors can dig in to see which one is winning. Each company continued to see rapid growth for the recent quarter.

Company YOY Revenue Growth Quarter Revenue Q1 2022 Market Share
Amazon Web Services 33% $19.7 Billion 33%
Microsoft Azure 40% N/A 22%
Google Cloud 36% $6.3 Billion 10%

Sources: Amazon, Microsoft, Alphabet, and Synergy. Note: Microsoft doesn't separate Azure's revenue from its Intelligent Cloud division. YOY = year over year.

Microsoft had the best quarter of the three but doesn't break out Azure's revenue or profitability. This lack of clarity is disappointing, but with a growth rate like that and second-place market share, Microsoft's Azure still conveys strength.

Despite being first in market share, AWS had the weakest quarter, and its operating margin dropped from last quarter. However, this drop is a reversion back to its standard operating margins.

AWS Historical Operating Margin
Q2 2022 Q1 2022 Q4 2021 Q3 2021 Q2 2021
29% 35% 30% 30% 28%

Source: Amazon.

Third-place Google Cloud is still working on reaching profitability. It lost $858 million this quarter, but this shouldn't be surprising as management is committed to investing in long-term growth for its cloud platform. This means it's spending heavily to catch up to its competitors.

While AWS may maintain its market leadership, it's hard to discount Azure's quarter. If I pick a winner for Q2, Microsoft gets the nod.

Which stock is the best buy?

Because all three companies are tech giants, cloud computing is not the only industry these businesses are focussed on. When picking which stock to buy, you must dig into the other businesses, as well.

Microsoft's total revenue grew 12% year over year, although its net income was only up 2%. Alphabet's quarter was similar, with 13% revenue growth, but its profitability fell, and net income decreased by 14%. Despite a challenging quarter, both companies grew revenue and produced solid profits. (Alphabet's reduced 28% operating margin is still healthy.)

Amazon's international and North American retail segments both lost money during the quarter, leaving AWS as the only profitable division. Net sales were only up 7% companywide, and the company had a free cash flow burn of $23.5 billion during the quarter.

Amazon is dealing with tough comparisons amid the e-commerce boom it experienced during the pandemic and isn't high on my investment list. As a result, in my opinion, Amazon isn't a better purchase than Microsoft or Alphabet, despite a solid AWS division.

Comparing Microsoft's and Alphabet's valuations reveals a lot:

GOOG PE Ratio Chart

GOOG PE Ratio data by YCharts.

While the two businesses used to trade at a similar valuation, over the past year, they've decoupled. This split is mainly due to a softening advertisement environment driven by a weaker economy. Because Alphabet derives over 80% of its revenue from advertising, investors aren't confident about the stock's near-term prospects.

This aspect makes it the better buy over Microsoft, which trades at a premium valuation, leaving little upside potential. On the other hand, Alphabet is due for a rebound once the economy recovers.

While I think all three are potential buys, Alphabet's discount makes it a top pick when it comes to selecting cloud stocks because I'm investing for the long term (three to five years). However, should one of these companies be forced to spin off its cloud division due to antitrust concerns, I would be an immediate buyer of that newly formed business.