For years, seniors have been told to unload their stocks once they reach retirement and move over to safer investments -- namely, bonds. And to an extent, that advice still makes sense. Because stocks are far more volatile than bonds, holding them becomes riskier for seniors. Unlike younger workers, who have time to ride out the market's ups and downs and can therefore afford to invest their nest eggs heavily in stocks, retirees need those savings to cover their day-to-day expenses. And if they keep too much money invested in stocks, and the market takes a dive, they stand to lose a big chunk of their savings without much chance of a full recovery.

But despite the risk involved, if you're retired, it pays to keep a chunk of your portfolio in stocks. If you don't, you may have a hard time maintaining your purchasing power over the course of what could be a very lengthy retirement.

Senior man holding a sheet of paper

IMAGE SOURCE: GETTY IMAGES.

You need those higher returns

Why take the risk of investing in stocks? It's simple: Stocks have historically delivered significantly higher returns than bonds, which are safer but don't offer nearly the same amount of growth. There was a time when bonds performed better, and you could count on them to do a decent job of keeping up with inflation. However, in today's low-interest-rate environment, going heavy on bonds could hurt you, especially since seniors are living longer these days. As such, you need to put your money somewhere it can actually grow, and these days, the stock market is pretty much the best way to achieve that goal.

But let's go back to life expectancies for a second, because it factors into why seniors need to be willing to hold some stocks. Though the average 65-year-old today is expected to live into their mid-80s, about 25% of today's 65-year-olds will live past 90, while one in 10 will live past 95. If you retire at 65, which has long been a popular age to leave the workforce, and wind up in that 10% who make it past 95, you'll be looking at a 30-year retirement to fund.

Now if you adopt a smart withdrawal strategy, such as the 4% rule, you might make your savings last 30 years. The 4% rule has a long history of success, and it states that if you begin by withdrawing 4% of your nest egg during your first year of retirement, and adjust subsequent withdrawals to account for inflation, your savings should last 30 years. But the 4% rule also assumes a relatively equal mix of stocks and bonds, which means that if you completely unload the former, your investments simply won't generate enough income to sustain that sort of withdrawal rate year after year. Furthermore, one major problem with the 4% rule is that bonds today aren't performing as well as they were back when the theory was established, which means that if you aren't willing to compensate by going a bit more stock-heavy, your nest egg could fall short.

Stocks offer more than just returns

Though stocks are known to deliver higher returns than bonds, another motivating factor for keeping stocks in your portfolio as a retiree boils down to dividends. A big reason retirees like bonds is that they offer a reasonably reliable stream of income in the form of regular interest payments. But if you load up on dividend stocks, you'll get a similar benefit in the form of quarterly payouts.

Furthermore, if you buy stocks issued by solid, established companies, there's a good chance you'll continue receiving those dividends even if the market starts to underperform. And that income might be enough to tide you over until the market rebounds so that you don't have to actually lose money by selling your stocks at a low point.

Striking a balance

So how much of your portfolio should you keep in stocks as a senior? It depends on how long you need your nest egg to last, how much income you have coming from other sources (like part-time work or a pension), and how much risk you can stomach. But if you want to increase your likelihood of beating inflation, you should plan on keeping at least half of your portfolio in stocks, and possibly more.

If you don't like the idea of hanging on to individual stocks in retirement, you could always keep your stock money in exchange-traded funds. ETFs offer the benefit of built-in diversification, which will protect you somewhat from the market's volatility.

While it's true that stocks carry a degree of risk, particularly in retirement, an even greater risk to your long-term financial security is your portfolio's inability to knock inflation on its tail. You may need to creep outside your comfort zone, which is no doubt more difficult once you're older, but if you limit yourself to safe investments in retirement, you may be setting yourself up for hardship down the road.

The Motley Fool has a disclosure policy.