Warren Buffett just won a $1 million bet—and highlighted one of the best ways to grow wealth

In 2007, legendary investor Warren Buffett made a $1 million bet against Protégé Partners that hedge funds wouldn't outperform an S&P index fund, and he won.

Buffett's choice fund, the Vanguard 500 Index Fund Admiral Shares, returned 7.1 percent compounded annually, while the basket of hedge funds his competitor chose returned an average of only 2.2 percent, the Wall Street Journal reports.

Buffett and Protégé Partners originally put about $320,000 each into bonds that would appreciate to $1 million over the course of their wager, but because the bonds appreciated much faster than expected, they decided to buy 11,200 Berkshire B shares, which are now worth $2.22 million, according to the Journal.

And, as decided in the original bet, the money will go to charity. Buffett's pick: Girls Inc., a organization that supports young girls in Omaha through after-school and summer programs.

Although there are no guarantees in the stock market, Buffett's conviction that index funds are a smart investment is solid advice that almost anyone can follow.

Index funds are a form of passive investing. They hold every stock in an index such as the S&P 500, including big-name companies such as Apple, Microsoft and Google, and offer low turnover rates, so fees and taxes tend to be low as well.

Buffett specifically recommends them as a way to boost retirement savings. "Consistently buy an S&P 500 low-cost index fund," he told CNBC's On The Money. "I think it's the thing that makes the most sense practically all of the time."

Warren Buffett, Chairman and CEO of Berkshire Hathaway.
Adam Jeffery | CNBC

That makes sense for two reasons: Index funds are inexpensive and aren't tied to the success of one single entity.

"The trick is not to pick the right company," Buffett says. "The trick is to essentially buy all the big companies through the S&P 500 and to do it consistently."

Individual stocks also cost more to manage, which means advisors take a larger chunk of your earnings.

"Costs really matter in investments," Buffett says. "If returns are going to be 7 or 8 percent and you're paying 1 percent for fees, that makes an enormous difference in how much money you're going to have in retirement."

Buffett's not the only business titan to champion index funds. Mark Cuban gave the thumbs up during an interview with Hayman Capital Management founder Kyle Bass, MarketWatch reports. If you don't know too much about markets, the best way to invest your money right now is to put it in a cheap S&P 500 SPX fund, the self-made billionaire said.

Tony Robbins agrees. "Index funds take a 'passive' approach that eliminates almost all trading activity," he writes in his book, "Unshakeable," in which he explains that funds eliminate the human error — and therefore the risk — that comes from trying to pick stocks individually.

"When you own an index fund, you're also protected against all the downright dumb, mildly misguided or merely unlucky decisions that active fund managers are liable to make," Robbins writes.

Like this story? Like CNBC Make It on Facebook!

Don't miss: