Microsoft (MSFT -0.18%) started out as a software enterprise in 1975. Its flagship Windows operating system is still used by billions of people globally, despite launching way back in 1985. But the company has expanded far beyond its roots, and it now has a large presence in industries like cloud computing, gaming, and artificial intelligence (AI).

Microsoft embraced AI in early 2023 when it announced plans to invest $10 billion in ChatGPT creator OpenAI. It has since woven the start-up's technology into its entire product portfolio, placing AI at the fingertips of millions of customers worldwide.

The partnership is already delivering financial rewards for investors, and it's a key reason Microsoft is now the most valuable company in the world with a $3 trillion market capitalization. However, that doesn't mean it's too late to invest in its stock -- in fact, when you look back five years from now, you'll likely be glad you'd taken the leap today.

AI could be Microsoft's most valuable opportunity ever

The AI industry is still in its infancy, and yet, Wall Street analysts already think it has enough potential to add between $7 trillion and $200 trillion to the global economy over the next decade. AI chatbots can rapidly generate text, images, videos, and even computer code, which could drive a productivity boom across the corporate world.

Understandably, thousands of companies are racing to integrate AI into their operations. Microsoft is at the forefront of this push, and it has already successfully monetized the technology in a measurable way

Using a combination of its own models developed in-house and OpenAI's latest GPT-4, Microsoft created an AI assistant called Copilot. It's already available in products like Windows, the Edge internet browser, the Bing search engine, and the Office 365 suite (Word, Excel, and PowerPoint).

In the fiscal 2024 third quarter (ended March 31), Microsoft said 60% of the Fortune 500 companies were using Copilot for 365, with giants like Amgen, Cognizant, and Nvidia each purchasing over 10,000 seats. This is a massive financial opportunity for Microsoft, because there are more than 400 million existing 365 seats that could add Copilot to their plans by paying an additional fee.

Copilot for applications like Windows, Edge, and Bing present a different opportunity for Microsoft. Seeking information from an AI chatbot is far more convenient than using a traditional search engine like Google, which forces the user to sift through webpages for answers. Therefore, if Microsoft can capture enough traffic through the aforementioned applications, there might be an opportunity to create new revenue streams by selling advertising spots.

Two people talking while walking past servers inside a data center.

Image source: Getty Images.

The cloud continues to shine, led by Azure and AI

Microsoft generated $61.9 billion in revenue during its fiscal Q3, up 17% year over year and comfortably above Wall Street's forecast of $60.8 billion. Intelligent Cloud remained the largest of Microsoft's three core business units, and its revenue increased 21% to $26.7 billion.

Azure is Microsoft's cloud computing platform, and it offers hundreds of solutions to businesses all over the world to help them operate in the digital age. A growing number of those solutions revolve around AI.

Microsoft is investing heavily in building data center infrastructure fitted with the latest graphics processing chips (GPUs) from the likes of Nvidia, which deliver the computing power developers need to build, train, and deploy AI models.

The company also created Azure OpenAI Service to give companies access to the most advanced pre-built AI models, including GPT-4, DALL-E, and even Llama, which was developed by Meta Platforms. They can help accelerate the development of customer-facing AI applications, saving companies countless amounts of time and financial resources. As of Q3, Microsoft said 65% of the Fortune 500 were using Azure OpenAI Service.

Azure (which operates under the Intelligent Cloud segment) saw revenue growth of 31% last quarter, the fastest pace in more than a year. That growth included a contribution of 7 percentage points from AI specifically, up from 6 points just three months prior. Simply put, AI is clearly additive to Microsoft's cloud business already, and this opportunity is just warming up.

$3 trillion doesn't have to be a stopping point for Microsoft

To accompany its strong revenue growth, Microsoft also carefully managed its costs and delivered a 20% year-over-year increase to earnings per share during the quarter. With its fiscal 2024 year set to wrap up in June, Wall Street analysts expect the company to deliver total earnings of $10.99 per share.

Based on Microsoft's current stock price of $406.66, that places it at a price-to-earnings (P/E) ratio of 37, a sizable premium to the Nasdaq-100 technology index's forward P/E ratio of 26.

However, there's a reason investors are willing to pay up to own a slice of the world's largest company. It has established an early lead in the AI space, positioning itself to capture a healthy share of the incredible economic impact this technology could deliver in the coming years. Plus, since Microsoft operates across so many industries serving both consumers and businesses, it will likely find new ways to monetize AI that analysts haven't even considered yet.

Shares in a quality company like Microsoft tend to appear cheaper the further into the future you look, so investors with a long-term time horizon should end up being very happy they bought in today, especially when they reflect back on this moment in five years.