New: Evolving the Heatmap: Dow Jones, Nasdaq 100, Russell 2000, and More

Learn More

Palantir vs. IBM: Which Defense AI Stock Is the Better Long-Term Bet?

By Leo Sun | September 23, 2025, 6:15 AM

Key Points

Palantir (NASDAQ: PLTR) and IBM (NYSE: IBM) are both profiting from the surge in government spending on AI-driven defense programs. Palantir, which already provides data mining and analytics services for most of the U.S. government, secured fresh contracts with the U.S. Army, the U.K. Ministry of Defence, and Canada's Department of National Defence over the past year. IBM signed new semiconductor security contracts with the Department of Defense.

Palantir and IBM generally attract different types of investors. Palantir, a popular stock among growth investors, has skyrocketed more than 400% over the past 12 months. IBM, often seen as a slower-growth value play, advanced just over 20%. But which of these AI-driven stocks is a better long-term investment right now?

Where to invest $1,000 right now? Our analyst team just revealed what they believe are the 10 best stocks to buy right now. Learn More »

A person being analyzed by AI algorithms.

Image source: Getty Images.

Palantir is growing, but it's becoming a meme stock

Palantir predicts trends by aggregating large amounts of data from disparate sources. Its Gotham platform serves its government customers, who use its software to organize missions and track individuals, while its Foundry platform serves large commercial customers. It also provides tools for creating customized AI applications within its platforms.

In the first half of 2025, Palantir generated 55% of its revenue from its government business and the remaining 45% from its commercial business. Most of its recent growth has been driven by its U.S. commercial business and a steady stream of government contracts.

Palantir's revenue surged 47% in 2020 and 41% in 2021, but only rose 24% in 2022 and 17% in 2023 as it grappled with the uneven timing of its government contracts and fierce macro headwinds for its commercial business. But in 2023, it turned firmly profitable as it streamlined its spending and reined in its stock-based compensation.

In 2024, its revenue rose 29% as its net income more than doubled. That acceleration was driven by the expansion of its U.S. commercial business as interest rates declined, the growing adoption of its tools for creating AI applications, as well as foreign and domestic conflicts that drove more government agencies to award Palantir with fresh contracts. Its soaring profits and rising market cap led to its inclusion in the S&P 500 and the Nasdaq-100.

From 2024 to 2027, analysts expect Palantir's revenue and earnings per share (EPS) to grow at a CAGR of 38% and 63%, respectively. Those growth rates are incredible, but its stock already trades at 305 times next year's earnings. Those meme stock valuations could set up Palantir for a steep pullback during a market downturn.

IBM is boring, but it's reasonably valued

From 2011 to 2020, IBM's annual revenue plummeted from $106.9 billion to $55.2 billion. That decline was largely caused by the softness of its core software, hardware, and IT services segments, its failure to keep up with its cloud-based competitors, and its desperate divestments. As many of its industry peers evolved into cloud and AI leaders, IBM got stuck in a destructive loop of cutting costs and buying back billions of dollars in shares to prop up its EPS.

But under Arvind Krishna, who took over as CEO in 2020, IBM broke that cycle by expanding its higher-growth hybrid cloud and AI businesses while spinning off its slower-growth managed infrastructure services segment as Kyndryl. Instead of directly competing against the top cloud companies, IBM relied on its open-source software subsidiary Red Hat to launch more AI services that could be wedged in the "hybrid" space between public and private clouds.

That flexible approach enabled IBM to cast its net over a wider range of customers and process more data that flowed between private on-site servers and public cloud services. As a result, IBM's revenue and EPS finally rose at a CAGR of 3% and 1%, respectively, from 2020 to 2024.

From 2024 to 2027, analysts expect IBM's revenue and EPS to grow at a CAGR of 5% and 16%, respectively, as it continues to expand its hybrid cloud and AI businesses. It still looks reasonably valued at 27 times next year's earnings, and its pays a decent forward yield of 2.5%.

The better buy: IBM

Palantir is expanding rapidly, but its growth rates can't sustain its nosebleed valuations. So instead of paying the wrong price for the right stock, investors should stick with IBM. IBM isn't as exciting as Palantir, but it looks like a much better buy at these levels.

Should you invest $1,000 in Palantir Technologies right now?

Before you buy stock in Palantir Technologies, 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 Palantir Technologies 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 $661,694!* 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,082,963!*

Now, it’s worth noting Stock Advisor’s total average return is 1,067% — a market-crushing outperformance compared to 190% for the S&P 500. Don’t miss out on the latest top 10 list, available when you join Stock Advisor.

See the 10 stocks »

*Stock Advisor returns as of September 22, 2025

Leo Sun has no position in any of the stocks mentioned. The Motley Fool has positions in and recommends International Business Machines, Kyndryl, and Palantir Technologies. The Motley Fool has a disclosure policy.

Latest News

1 hour
2 hours
3 hours
3 hours
4 hours
Sep-22
Sep-22
Sep-22
Sep-22
Sep-22
Sep-22
Sep-22
Sep-22
Sep-22
Sep-22