Nvidia (NVDA -0.67%) and Microsoft (MSFT 0.26%) both made big bets on OpenAI, but they are coming at the opportunity from very different directions. Nvidia's move is about keeping its chips at the center of the artificial intelligence (AI) infrastructure buildout and expanding into the software side, while Microsoft's early investment let it weave OpenAI's large language models (LLMs) into its cloud computing and software businesses.

The question, though, is which stock is the better buy after their OpenAI investments.

Nvidia's big AI investment

Nvidia's plan to invest up to $100 billion in OpenAI is not just about buying a stake in a hot AI company. It also gives one of the companies that are leading the charge in AI infrastructure buildout financing, which it will then likely funnel back to Nvidia by buying or renting its graphics processing units (GPUs). This gives Nvidia a massive, long-term, guaranteed customer for its chips.

Locking that in helps solidify Nvidia's position as the essential infrastructure provider for the AI industry. Competitors like Advanced Micro Devices and Broadcom are fighting to break into the AI chip market, but by partnering closely with OpenAI, Nvidia helps solidify its position as the market leader. The deal also gives Nvidia financial exposure to OpenAI's software business. CEO Jensen Huang has said OpenAI could become the world's next multitrillion-dollar company.

Another underappreciated angle is that the two companies will work together at the chip, software, and systems level. That collaboration gives Nvidia a first look at the computing needs of the most advanced AI models, letting it shape future chips to match those workloads. That would give the company yet another edge.

Nvidia also has advantages that it built long before it invested in OpenAI. Its CUDA software platform, launched in 2006, locked in most AI developers since so much of the foundational code was written for it. Its NVLink interconnect, meanwhile, lets its GPUs operate as one giant unit. With OpenAI expected to lead the charge in AI data-center spending in the coming years, Nvidia looks as well positioned as any company to be a big winner.

Artist rendering of AI chip.

Image source: Getty Images.

Microsoft's early and smart AI play

Microsoft's investment in OpenAI was smaller in dollar terms, but it was transformational. It got in early when OpenAI's ChatGPT was starting to go mainstream, and that early move gave it preferred access to its models. That alone was a game-changer because it was able to become the growth driver behind its cloud computing unit, Azure.

The partnership helped create the Azure OpenAI Service, which lets Microsoft's enterprise customers tap into OpenAI's most advanced models using its infrastructure. That initial exclusive access to OpenAI's models drew in customers looking to use them to power their AI workloads. Azure growth has been skyrocketing, including last quarter when it soared 39% despite running into capacity constraints.

Microsoft also integrated OpenAI's technology directly into its software, using its models to create its Copilot AI assistants. Its Copilot can do many things, from simply summarizing a document to allowing someone to use Python in Excel using only natural language. The bottom line, though, is that it can help workers be more productive, and at $30 per user per month, it's an affordable way for companies to help increase worker efficiency, while also being a nice growth drive for Microsoft.

Another advantage of Microsoft's OpenAI investment is that it gives it early access to OpenAI's newest technologies, which cuts its own development risk and cost. By being first in, Microsoft secured a preferred-partner status that its competitors still don't have.

The better investment versus the better buy

Microsoft clearly made the better OpenAI investment by getting in early. Its initial investment is now worth way more than it was just a few years ago. At the same time, that relationship has been critical in helping drive the company's own growth.

Nvidia's investment is coming much later, but it locks in massive chip sales and helps cement its role as the backbone of AI infrastructure. It also gives it exposure to OpenAI's potential upside and to work together to advance the future of AI.

If you're judging by who got the better deal on OpenAI, that was Microsoft. But if you're looking at the stocks today, Nvidia looks better positioned moving forward, given the massive opportunity still ahead of it, helped by its OpenAI investment.