Sure, buying and selling stocks can be fun, but isn't creating lasting wealth, generational wealth that can be passed to your descendants, the goal? And that can be an elusive goal as the market goes up and down over time, as do share prices. Sometimes, things go sideways and we have a market crash, from which some stocks never recover.

So, how can investors give their portfolios the best chance at standing the test of time? Diversification is the answer. Simply put, don't put too many eggs in one basket. Investors can build a portfolio with exchange-traded funds (ETFs) that owns shares of many businesses and with individual stocks of diverse businesses that have proven they can perform over the long haul.

Consider tucking these three into your portfolio. Decades from now, you might be glad you did.

1. Invest your money with Warren Buffett

Investing great Warren Buffett has built his legacy through his holding company, Berkshire Hathaway (BRK.A -0.76%) (BRK.B -0.69%), an investing empire carrying an $860 billion market cap today. The reality is that Buffett, 93, won't be around decades from now. However, Berkshire is built with staying power, arguably unmatched by any company on Wall Street.

For starters, Berkshire owns many private companies across various industries. Some of Berkshire's well-known consumer-facing companies include GEICO Insurance, Duracell, Dairy Queen, Fruit of the Loom, and Clayton Homes. Additionally, Berkshire owns a sprawling collection of industrial assets, including railroads, oil and gas pipelines, and utilities. If that wasn't enough, Berkshire has a portfolio of public companies worth over $370 billion, and an additional $157 billion in cash.

BRK.A Total Return Price Chart

BRK.A Total Return Price data by YCharts

These many assets generate earnings and investment income, which all flow to Berkshire's cash hoard, deployed as Buffett and his management group see fit. Berkshire Hathaway stock doesn't pay a dividend, but it has allocated its resources well enough to outperform the S&P 500 as an investment for years. Berkshire is one of the few stocks you can buy and forget, because your money is tied up in a sprawling business built to last forever.

2. Don't fight the market, join it

Many invest to beat the market, i.e., outperform the S&P 500 index, probably the most common investing benchmark. But frankly, it's tough to do that consistently. Buffett himself recommends investing in index funds that hold shares of all the companies in the S&P 500.  For a lot of investors, it makes sense to ride the S&P 500 by investing in an ETF like the Vanguard S&P 500 ETF (VOO 1.00%).

The S&P 500 represents 500 of the most prominent U.S. companies. It's not a static list, either. A better business will replace a company that falls off. In other words, it's a turn-key portfolio of the best companies in the world's most prolific economy. Will things get dicey sometimes? Sure. Bear markets, which involve drops of at least 20% from highs, happen a couple of times a decade.

^SPX Chart

^SPX data by YCharts

But whether it's a recession, war, or a global pandemic roiling the broader market, the S&P 500 has always rebounded and grown to new highs. The Vanguard S&P 500 ETF has done a great job tracking it, and for a tiny 0.03% expense ratio.

3. Diversify into big tech with a single ETF

Big technology companies are driving new industries like cloud computing and artificial intelligence (AI). That's been underlined by the performance of the "Magnificent Seven" stocks, which have collectively run circles around the broader market. But instead of trying to predict which of these stocks will get hot (and when), consider the Invesco QQQ Trust (QQQ 1.54%) instead. This ETF focuses on big technology and innovation stocks.

The "Magnificent Seven" are littered throughout the Invesco QQQ's top holdings. Microsoft, Apple, Amazon, Nvidia, Meta Platforms, Tesla, and Alphabet comprise 40% of the fund's holdings. Big technology's growth has led to stellar fund performance in recent years against all three primary U.S. stock market benchmarks.

QQQ Chart

QQQ data by YCharts

This doesn't guarantee that the outperformance will last. Still, AI could grow into a multitrillion-dollar industry, and these colossal technology companies have the deep pockets to invest and grab that opportunity by the horns. Having long-term and diversified exposure via the Invesco QQQ is a simple way to ensure that your portfolio is exposed to that upside.