Should you buy a home or invest?

The path toward retirement and financial independence usually involves buying a home and investing for retirement and the future. But, what if you had to choose?

William Cowie posed this question to me recently and asked which path I would take to financial independence if given the option. My answer: I would invest for the future and forgo the house in a New York minute. Let's look at why I think that makes sense.

Performance over time - 1940 to present

Throughout history, housing prices have appreciated over time. Because of this, both real estate investors and homeowners have built wealth with ease by building equity in their homes and properties.

According to U.S. Census Bureau estimates, median home values nearly quadrupled over the 60-year period since the first housing census in 1940, adjusted for inflation. To give an example, a $30,600 home in 1940 would be worth approximately $119,600 in the year 2000.

Since 2000, the appreciation of home prices has slowed down considerably, with 2007 to 2011 actually sending home values downward. But what goes down, must come up, right? Just during 2014 alone, housing values increased nationally by 6.84 percent, 5.52 percent, and 4.55 percent for the first three quarters.

What am I getting at? Even though real estate booms and busts over time, housing prices consistently trend upward. And homeowners who get in at the right time can sometimes build a lot of wealth simply by buying the right house and staying put.

But here's the thing. Real estate isn't the only way to build wealth; investing consistently is the key to growing rich. The total S&P 500 return from 1940 to 2015 is 1104.268 percent, which works out to an annualized return of 7.42 percent.

Let's imagine for a moment that someone opted to invest $30,600 in 1940 and simply leave it there. After earning compound interest at a rate of 7.42 percent for 60 years, they would have $2,243,005.35!

Personal math favors investing

Obviously, that is an oversimplification. After all, the typical house hunter in 1940 probably wouldn't have $30,600 laying around to invest, plus they needed a place to live! Still, it illustrates the power of compound interest, one of the many wonders in the world.