Real estate is great in retirement because the income tends to be predictable, and it rises with inflation, like an indexed pension. People may prefer these investment merits over stocks that can be volatile day to day, let alone year to year. The key for stock investors in retirement is to remind yourself not to sell your stocks all at once—ideally, you should be withdrawing a low to mid-single-digit amount from your portfolio every year, part of which will come from dividends and interest anyway.
Real estate liquidity and transaction costs
There are two reasons to be careful about buying real estate that you might need to sell early in retirement.

Real estate is not always liquid. Sometimes, it can take longer than you would like to sell a property because the market is soft and you have to be patient. And with real estate, it is all or nothing. You cannot sell just a garage or a basement apartment—you must sell the whole property.
Transaction costs to buy and sell real estate are also significant. Everywhere but Alberta, Saskatchewan and the territories has land transfer tax. A buyer in Toronto might pay 3% all-in with municipal and provincial land transfer tax.
Real estate commissions to sell a property can be 5% or more, especially in Atlantic Canada or rural communities.
Adding in legal fees and incremental purchase and sale costs, an investor might pay 10% of the property value to buy and sell it. If these transactions happen 10 or 20 years apart, their impact may be negligible. But if they happen five years apart, especially during a period when prices do not increase much, you could negate most of your potential investment return.
As a result, an investor should be careful about buying a rental property they might need to sell early in retirement. Investors should also avoid waiting too long to sell when they are running out of more liquid assets like traditional investments.
Real estate as an inheritance
A lot of baby boomers have benefited from real estate price appreciation. They have also seen their children have a hard time buying real estate. As a result, some parents go out of their way to leave a real estate inheritance to their children, whether by purchasing rental properties or holding on to a cottage or a family home.
GIPHY App Key not set. Please check settings