Microsoft is seeing strong demand across its software and artificial intelligence (AI) offerings.
Oracle's accelerating cloud infrastructure business shows it is well positioned to capitalize on the growth in AI spending.
Artificial intelligence (AI) is ushering in a wave of opportunity across the economy. Gartner estimates AI spending will reach $2.5 trillion in 2026, up 44% year over year, and early projections point to $3.3 trillion in 2027.
Microsoft (NASDAQ: MSFT) and Oracle (NYSE: ORCL) are two tech giants that have robust AI capabilities. Microsoft is monetizing AI through everyday workflow tools, while Oracle is benefiting from the surge in AI computing demand through its cloud infrastructure. Here's what can sustain these companies' growth in the next five years.
Where to invest $1,000 right now? Our analyst team just revealed what they believe are the 10 best stocks to buy right now, when you join Stock Advisor. See the stocks »
Image source: Getty Images.
Microsoft has been a rewarding growth stock, doubling in value since 2021, and its run is far from over. Its revenue rose 18% year over year in the recent quarter, primarily driven by demand for AI features in Microsoft 365 and the Azure enterprise AI platform.
Microsoft has integrated its family of Copilot AI assistants across its productivity offerings, helping drive demand for its flagship productivity software. The Azure AI enterprise business is also growing rapidly and taking share in a $390 billion cloud market. This growth reflects the robust cloud infrastructure that Microsoft has built to deliver cutting-edge services that help companies do more with their data, such as building their own AI applications.
Demand for its offerings is pushing Microsoft to spend aggressively on data center expansion that could weigh on margins. But this spending also underscores Microsoft's financial fortitude, as it generated a whopping $147 billion in cash from operations over the trailing 12 months. This cash flow is fueling necessary investments to advance its AI capabilities, enhancing its competitive position.
The stock is reasonably priced at a forward price-to-earnings (P/E) multiple of 27. Investors can expect the stock to perform roughly in line with the business's future growth, with analysts currently forecasting 13% annualized earnings growth over the coming years.
Oracle's accelerating growth in its cloud infrastructure business makes it a compelling stock to buy. Enterprises are eager to secure the servers and chips needed for AI model training. Oracle's advanced database features, chips, and robust AI training capabilities are making it an attractive option for these businesses.
The cloud infrastructure business posted an impressive 68% year-over-year increase in revenue last quarter. While this segment accounts for just 25% of the company's total revenue, it suggests that Oracle is well positioned to gain share in the $159 billion cloud infrastructure services market. This market is expected to grow about 13% per year through 2034, according to Fortune Business Insights.
Oracle is competing with other cloud infrastructure providers like Microsoft, but its multicloud offering is one of its differentiators. This allows enterprises to run Oracle databases across multiple cloud providers. Customers value this flexibility, as Oracle's multicloud revenue grew 817% year over year in the recent quarter.
Oracle's momentum makes its current forward P/E multiple of 24 attractive. This is an attractive valuation, given analysts' expectations for 22% annualized earnings growth. At these share prices, investors could potentially double their money in five years.
Before you buy stock in Microsoft, consider this:
The Motley Fool Stock Advisor analyst team just identified what they believe are the 10 best stocks for investors to buy now… and Microsoft wasn’t one of them. The 10 stocks that made the cut could produce monster returns in the coming years.
Consider when Netflix made this list on December 17, 2004... if you invested $1,000 at the time of our recommendation, you’d have $464,439!* Or when Nvidia made this list on April 15, 2005... if you invested $1,000 at the time of our recommendation, you’d have $1,150,455!*
Now, it’s worth noting Stock Advisor’s total average return is 949% — a market-crushing outperformance compared to 195% for the S&P 500. Don't miss the latest top 10 list, available with Stock Advisor, and join an investing community built by individual investors for individual investors.
See the 10 stocks »
*Stock Advisor returns as of January 25, 2026.
John Ballard has no position in any of the stocks mentioned. The Motley Fool has positions in and recommends Microsoft and Oracle. The Motley Fool recommends Gartner and recommends the following options: long January 2026 $395 calls on Microsoft and short January 2026 $405 calls on Microsoft. The Motley Fool has a disclosure policy.