After passing $3 trillion in market cap on Dec. 5, Apple (AAPL -0.60%) stock is within 3% of its all-time high. Buying Apple decades ago produced unbelievable gains. But even more recent investors, like Warren Buffett-led Berkshire Hathaway, have seen market-crushing returns in a span of just seven years.

Once a company gets to a certain size, it can become difficult to support future growth. Going from a $1 trillion market cap to a $3 trillion market cap is one thing. Producing the same percentage gain by going from $3 trillion to $9 trillion is something we have never seen before and is hard to comprehend.

Apple stock may not triple anytime soon. But over time, it still has what it takes to build generational wealth. Here's why the tech stock is worth buying now.

Two people lean on a railing on a boat overlooking a body of water.

Image source: Getty Images.

Digesting weak results

Apple is one of the few companies that can post weak results over the short term without damaging the investment thesis one bit -- especially if the weak results are a result of industrywide slowdowns and cyclical factors rather than a shift in perception about Apple's products and services or its brand.

AAPL Revenue (Annual) Chart

AAPL Revenue (Annual) data by YCharts.

Apple's revenue, net income, and free cash flow all declined between fiscal 2022 and 2023. And yet, the stock is up about 50% year to date. You would be hard-pressed to find a company that grew by more than a trillion dollars in value in a single year despite posting negative growth. And yet, Apple stock still isn't that expensive, sporting a price-to-earnings ratio of 31.6.

Betting on the future

Apple's performance this year shows that the market expects the company to have no problem returning to growth. And there's reason to believe that Apple can become an even higher-quality business in the future thanks to the growth of its services segment.

Apple's services include Apple Pay, Apple TV+, Apple Podcasts, Apple Music, and more. Apple's services are higher-margin (typically around double the gross margin) than its physical products like an iPhone or other device. And they enhance the value of Apple's suite of products since many services are either free or relatively low-cost.

Services are a way for Apple to generate more sales from its core customer base. Expanding the depth of the ecosystem (through more services) and the breadth of the ecosystem (through more products) is a brilliant business model that should serve Apple well for decades to come.

The power of buybacks

Apple's ace in the hole for growing its earnings per share (EPS) no matter the market cycle is buybacks. Apple's relentless buyback program continues to generate value for shareholders. By reducing the outstanding share count, each share of Apple gets a higher percentage of earnings, which makes the stock a better value. Over time, buybacks can have a major impact on earnings.

For example, Apple has grown its net income by 145.5% over the last 10 years. But its diluted EPS is up 280.2% thanks to buybacks.

AAPL EPS Diluted (Annual) Chart

AAPL EPS Diluted (Annual) data by YCharts.

Over the last 10 years, buybacks have been just as important to Apple's EPS growth as the operations of the business have been.

Apple's deep pockets and dry powder act as a cushion in the event of a market sell-off. If Apple stock falls by quite a bit, Apple can take advantage of that volatility by swooping in and buying shares. If Apple stock goes on a big run like it did this year, Apple is still there to buy its own stock. Investors can be confident that Apple is by their side no matter what the market throws at them.

Apple's reliability makes it worth the price

When facing the prospect of investing in a stock like Apple that has been going up for so long and is currently around the highest it has ever been, it's a good idea to ask whether the company's growth is sustainable, if it's best days are behind it, and what is stopping the company from delivering market-beating returns in the future.

Apple has the market positioning and loyal customer base to avoid giving any ground to competition. It also has the cash flow to make acquisitions, accelerate its organic growth, and buy back its own stock to boost earnings per share. Growing its services business will improve Apple's overall margins and make it an even higher-quality business.

Out of all the big tech stocks, Apple stands out as having the lowest risk and maybe a potentially lower reward. But it also stands the best chance at producing generational wealth over time because of its wide moat and impeccable suite of products and services. Even with a higher-than-historic valuation, Apple stock is worth buying in December.