World

Elon Musk Is Unleashing SpaceX’s New War Chest to Solve His AI Problem

Elon Musk has admitted SpaceX lags behind rivals like OpenAI, Anthropic and even Google and Chinese open-source models in the race to build out artificial intelligence.

SpaceX founder Elon Musk on a big screen in New York’s Times Square during the company’s IPO.

He now has an $86 billion war chest to help change that. And the first target is getting enterprise customers who Musk hopes are willing to pay large sums for access to SpaceX’s tools and computing power.

The Elon Musk-led company reached a $60 billion all-stock deal to buy autonomous coding agent Cursor, a San Francisco startup that built a product used by the biggest AI labs and companies like Nvidia, British Airways and Deloitte.

SpaceX in recent months has restructured itself around the desire to build out its artificial-intelligence capabilities. It acquired Musk-controlled firm xAI earlier this year, which brought chat assistant Grok and the social-media site X, as well as large data centers into the fold.

In April, SpaceX said it had secured the option to buy Cursor. The big prize that comes with buying it now: a reliable stream of revenue.

Before it completed the largest initial public offering ever, Musk sold investors on his vision for AI that can take humans beyond Earth and “enable humanity to understand the universe.” On Tuesday, he touted AI’s potential to eventually write and debug code better than any human.

“AI will achieve Stockfish-level coding and generalized computer use,” Musk said about the Cursor deal, referencing a popular chess engine that can beat the best human players.

SpaceX recently started renting out its data-center capacity to rivals such as Anthropic and Google to bring in revenue—a timely strategy as the entire AI industry faces a computing crunch. The announced deals could drive $26 billion a year in revenue between 2027 and 2029.

SpaceX has also outlined plans to increase employment to meet Musk’s AI ambitions. During pre-IPO meetings with investors in April, SpaceX officials said the company would build out the xAI enterprise sales team, people familiar with the matter said.

Cracking the code

Cursor competes with Anthropic’s Claude Code and OpenAI’s Codex with a software development tool that helps companies code faster. Its product allows developers to toggle between different AI models to autocomplete, edit and review lines of code.

The company has grown at a breakneck pace. In 2025, the company’s annualized sales—an extrapolation of the next 12 months’ revenue based on recent sales—grew to $1 billion from $100 million. In early June, that figure shot up to $4 billion, according to a person familiar with the matter.

More than half of Cursor’s revenue comes from enterprise customers, and Cursor expects to continue to partner with other AI model providers, a person close to the company said.

The purchase price for Cursor was more than double its $29.3 billion valuation in a November funding round.

SpaceX’s acquisition could help fill in a leadership gap at xAI since Musk said the company needed to be “rebuilt from the foundations up.” xAI laid off staffers, including its founding team. Cursor CEO Michael Truell is viewed as a rising star in the AI industry, where competition is steep for the top talent.

“Lots to do together. Excited to be joining forces with @SpaceX to build useful AI,” Truell wrote on X.

Steep costs for AI investment

Speaking from the witness stand in a second civil lawsuit against OpenAI last month, Musk ranked the top AI models, laying bare how much work SpaceX’s xAI has to do to reach rivals.

“Anthropic would currently be number one; OpenAI would be the second biggest; Google would probably be the third biggest; the Chinese open-source models would probably be fourth,” he said. “Then xAI would be fifth.”

While SpaceX dominates at its core businesses of rocket launches and satellite internet, xAI was losing money and had few customers when it was acquired. One key AI customer, the Pentagon, has had internal strife over the safety and security of the company’s Grok chatbot, The Wall Street Journal has reported.

That is a really big problem, based on the amount of investment needed to train AI models, employ engineers and build computing infrastructure.

Last year, the AI business brought in $3.2 billion in revenue but reported $6.4 billion in losses, according to securities filings. Losses piled up in the first quarter too. The business generated $818 million in revenue and $2.5 billion in red ink.

There are also limits on how much SpaceX can spend from its IPO cash pile toward AI endeavors.

Some of the IPO proceeds will go to repay $20 billion in debt from a bridge loan the company took out in March. SpaceX has also announced billions of dollars in new projects, including at least $55 billion to build a chip-fabrication facility in Texas, and it plans to buy spectrum for its Starlink service.

Still, in Musk’s view, the market opportunity in AI is too big to pass up.

SpaceX told investors ahead of its IPO that the company’s products and services are targeting a potential $28.5 trillion market, one it deemed the largest “in human history.” AI products accounted for $26.5 trillion of the total, and enterprise applications made up most of the AI products.

Analysts at Morningstar have questioned how SpaceX calculated its potential market and pegged the company’s implied valuation being far below current trading levels.

Others, including Goldman Sachs and Morgan Stanley—companies that helped manage SpaceX’s IPO—projected SpaceX was primed for substantial AI-fueled growth. Both firms pegged SpaceX’s revenue being near $160 billion in 2028, more than eight times 2025 levels.

Write to Becky Peterson at becky.peterson@wsj.com and Angel Au-Yeung at angel.au-yeung@wsj.com