Warren Buffett once famously claimed his favorite holding period for a stock was "forever." But that quote is often misunderstood -- it doesn't mean the Oracle of Omaha never sells any stocks. It also doesn't mean investors should stubbornly hold on to shares of broken businesses.

Instead, stocks that can be held forever often share three strengths: They dominate their respective markets, they generate plenty of cash, and they still have decades of growth ahead. Here are three stocks in my portfolio that check all three boxes: Disney (DIS -0.27%), Amazon (AMZN -2.73%), and ASML Holding (ASML -3.06%).

A canvas bag, a rising 3D chart, and an hourglass on a table.

Image source: Getty Images.

1. Disney

I accumulated most of my shares of Disney in 2012, 2014, and 2016. I expected the growth of its film and theme park businesses -- buoyed by Marvel, Star Wars, Pixar, and its other evergreen franchises -- to offset the impact of cord cutters on its cable business.

Disney has repeatedly tested my patience over the years, especially with the costly expansion of its streaming platforms and the shutdown of movie theaters and theme parks during the pandemic. Yet I stuck with Disney because no other entertainment company can match its long-term appeal.

Disney's network of theme parks should continue to evolve and expand, its box office hits should outweigh its bombs, and Disney+ will likely achieve its goal of 230 million to 260 million subscribers by the end of fiscal 2024 -- and finally silence any lingering concerns about its loss of cable TV viewers.

Disney already generated a total return of more than 400% over the past decade, but I believe its growth engines will propel it even higher over the long term -- which makes it a great stock to hold forever.

2. Amazon

I bought most of my shares in Amazon in 2015 and 2016. I turned bullish on Amazon after it started disclosing the profitability of its cloud platform AWS (Amazon Web Services), since I realized it could easily support the expansion of its lower-margin retail business with the cloud unit's profits.

None of Amazon's brick-and-mortar and online competitors had that unique strength. Meanwhile, Amazon leveraged AWS' growth to expand its e-commerce ecosystem with lower-margin and loss-leading strategies, including new perks for Prime members and cheap hardware devices.

That virtuous cycle generated plenty of cash for fresh acquisitions, including its $13.7 billion takeover of Whole Foods in 2017 and its planned takeover of MGM Studios for $8.5 billion. Those acquisitions highlight Amazon's unique ability to expand across seemingly unrelated sectors, then tether those sectors' customers back to its prisoner-taking Prime ecosystem of over 200 million paid subscribers.

Amazon is already synonymous with online shopping in many countries, and AWS is already the world's largest cloud infrastructure platform. I expect both businesses to remain strong for decades to come -- and I'm willing to hold on to my shares to profit from those gains.

3. ASML

ASML is one of the latest additions to my portfolio. I started accumulating shares of the Dutch semiconductor equipment maker in early March for a simple reason: The world's top chipmakers can't manufacture their most advanced chips without its lithography systems.

ASML sells the world's most sophisticated EUV (extreme ultraviolet) lithography systems, which print circuit patterns onto silicon wafers. The world's most advanced chip foundries -- TSMC (TSM -2.56%), Samsung, and Intel (INTC -1.98%) -- all need to use its EUV systems.

ASML developed its technology over the past two decades, so it doesn't face any meaningful competitors in the high-end EUV space. As a result, its margins continue to expand, and it consistently plows its excess cash into buybacks and dividends.

In the near-term, ASML will benefit from the ongoing semiconductor shortage as the world's largest foundries purchase even more EUV systems. It's also getting ready to roll out next-gen EUV systems, called high-NA systems, for the production of even smaller chips. Over the long term, ASML will remain the linchpin of the global semiconductor market -- and remain a rock-solid long-term investment.