Shares of Palantir Technologies (PLTR -1.10%) surged 480% over the past year as the artificial intelligence analytics company's sales and earnings both jumped. Palantir's services are used by the U.S. government and companies to make sense of their data and make better decisions, and the company is likely still in the early innings of the AI boom.

That's the good news. The not-so-great news is that Palantir's rapid share price gains pushed its price-to-earnings ratio up to 690. That sky-high number is solidly in the nosebleed section of any stock valuation, and then some.

While some investors may be OK with paying a hefty premium for Palantir's shares, many won't be. If you're one of them, here are two other AI stocks that are great to own instead.

A processor with the letters "AI" on it.

Image source: Getty Images.

1. Nvidia

Nvidia (NVDA -0.80%) is at the top of many investors' lists of AI stocks, and with good reason. Nvidia is leading the way in the AI semiconductor space and the company's processors account for an estimated 75% to 95% of all artificial intelligence semiconductors. That lead won't be overcome any time soon, giving Nvidia a significant advantage in AI processing for years to come.

What's more is that Nvidia's sales and earnings are through the roof. Data center revenue spiked 73% in the first quarter of fiscal 2026 to $39 billion and the company's non-GAAP (adjusted) earnings were up 33% from the year-ago quarter. Nvidia's management estimates revenue will climb 50% in the second quarter to $45 billion.

Nvidia stock is pricey, but it's far cheaper than Palantir's. The company's shares have a P/E ratio of about 56, which is on par with the rest of the semiconductor industry right now. And there are some solid indicators that more AI processor demand is on the way, considering that Microsoft, Meta Platforms, Amazon, and others have all said they'll spend hundreds of billions of dollars on AI data centers over the next several years.

2. Taiwan Semiconductor Manufacturing

Taiwan Semiconductor Manufacturing (TSM -0.63%), which is also called TSMC, makes the processors that many companies design. In contrast, Nvidia is a chip designer, not a fabricator.

TSMC's business has been booming thanks to the surge in AI processor demand, and the company's management says that AI revenue will double this year compared to last year's sales. Considering the company's earnings surged 61% in Q2 2025, any investor fears that artificial intelligence demand is cooling down should be put to rest.

Like Nvidia, TSMC is essentially unrivaled in what it does. The company makes an estimated 90% of the world's most advanced processors. And just as impressive is the fact that TSMC's stock trades at somewhat of a discount right now, with a P/E ratio of just 29, which is right at the S&P 500 index's average.

Hedge your AI bets

While Palantir's shares could continue climbing, it's wise to spread out your investments across a handful of AI stocks. At times, it might seem like you're missing out on some of the gains that Palantir could make, but investing in some of the tangible parts of AI -- processors and manufacturing -- could be a good way to include a little diversification into an artificial intelligence-heavy portfolio.

And given that fact that Nvidia and Taiwan Semiconductor have much more attractive valuations than Palantir, now could be a good time to start a position.