People living in the property are almost always buying it as both a place to live and as an investment.
Investment is not the same as speculation.
Even without guaranteed appreciation in value people will buy homes because they have an asset compared to alternatives like renting. When renting you’re guaranteed a loss on rent paid.