Well housing is a good investment once you pay it off and stay in that home for an extended period of time. The problem is people just want buy ever larger homes. I mean look at the average square footage of homes in the 1970s which was 1500 sqft and by 2014 its 2,657 sqft (https://247wallst.com/special-report/2016/05/25/the-size-of-...). People are buying way over their means.
I purchased a 1800 sq ft home when I was 22 that I am still living in today (I am 45) with a 15 year fixed mortgage. I paid the mortgage off and have lived rent/mortgage free for the past 8 years. Assuming I live here for another 12 years, that will be 20 years of rent/mortgage free living. And yes I am married and have a 2 year old.
And when I do eventually sell, I will get back all the interest I paid and then some even adjusted for inflation. The problem is people just keep jumping int every larger homes. As soon as they can.