There has been no company that has gotten more attention in the past couple of years than Nvidia (NVDA -2.42%). The leader in graphics processing units (GPUs) that support artificial intelligence (AI) training has won over investors in remarkable fashion.
In just the last five years, this top AI stock has soared 1,590%. For comparison's sake, the S&P 500 index is up just 95% over the same period. Investors are clearly enamored with the business, which they believe is and will continue to be a winner as an AI-driven technological shift takes shape.
But for investors new to the company or those looking to increase their position, is Nvidia still a buy with shares trading at their all-time high?

Image source: Nvidia.
Incredible financial performance
The demand for Nvidia's data center GPUs is impossible to overstate. Between fiscal 2020 and fiscal 2025, the company's total revenue increased at a compound annual rate of 64%. And during the first quarter of fiscal 2026 (ended April 27), the top line soared 69% year over year to $44.1 billion.
Nvidia's profitability is also impressive, driven by strong pricing power. Net income totaled $18.8 billion last quarter, and the company's net profit margin has averaged a superb 36% over the past five years.
Such an exceptional financial performance has only been possible thanks to the dominant position Nvidia has established in AI. It has positioned itself as the leading picks-and-shovels play, supporting the development of the AI infrastructure atop which platforms and apps will be built. At the end of the day, Nvidia shareholders don't need to choose between OpenAI's ChatGPT, Anthropic's Claude, or Alphabet's Gemini -- they stand to benefit as long as the overall AI industry continues to expand.
Investors shouldn't overlook key risk factors
Nvidia recently announced that it should soon be able to export and sell its H20 chips in China, following the U.S. government's approval of the company's application for export licenses. Management stated that existing export restrictions resulted in $2.5 billion in lost H20 revenue last quarter.
While the new approval is a positive development as it reopens a major market for AI chips, it also highlights just how dynamic the trade situation has been. The Trump administration is willing to change course in an instant, and as AI technology is increasingly viewed as a topic with geopolitical ramifications, the tense relationship between the U.S. and China can still affect Nvidia's business in the future. This risk shouldn't be ignored.
There's also the uncertainty around what a possible recession might do to all this AI spending. Should economic conditions deteriorate, executives will likely cut their capital spending plans, putting Nvidia's sales under pressure.
Nvidia's valuation is hard to believe
There aren't many stocks that have gone parabolic like Nvidia has. After all, over the past five years, shares have climbed nearly 17-fold. Even when you think the company has gotten too large or the market cap, now at $4.2 trillion, can't go any higher, Nvidia continues to prove the skeptics wrong. Along the same vein, it's hard to believe the current valuation is still reasonable.
While shares trade at an all-time high, investors can buy the stock at a forward price-to-earnings ratio of 39.9. Meanwhile, the consensus analyst estimate calls for earnings per share to grow at an annualized pace of 32% between fiscal 2025 and fiscal 2028. That level of growth makes the premium valuation look far more reasonable.
With Nvidia's dominance in the industry, impressive growth, and substantial margins, the case for buying the stock remains compelling, even as it trades near record levels.