Let me be clear what I think. If one has a fixed need for cash, then holding CDs with maturities up to that date works-- your portfolio is immunized.
Yes, if you have a known nominal liability, then a CD or Treasury with a maturity matching the liability is a risk-free asset. Unless there are other relevant factors, the security with the higher yield is preferable (and this has consistently been CDs over at least the last seven years for maturities out to 10 years). If the liability is real, then a TIPS of matching maturity is the riskless asset.
So if what you' want is a riskless asset for your particular needs, we know how to select that. However, you may be willing to take some risk in return for higher expected return. This is why most of us hold some stocks, which have no maturity date, and therefore are never riskless in terms of meeting a known liability. Many of us also take some credit risk in our fixed-income holdings, even though this adds uncertainty to our expected return over any given time period.
Similarly, many of us take term risk and/or reinvestment risk and/or inflation risk that may cause our fixed income to not be riskless given a timeframe and nature (nominal or real) for future liabilities. Again, many Bogleheads hold nominal, intermediate-term bond funds (or even short term), even though the liabilities that these will eventually be used to fund are long-term and real, and they count on their stocks to provide the long-term, real growth that they need. They have chosen to take certain risks in return for a higher expected (but uncertain) return than they can get with long-term TIPS, which would be the more appropriate asset if minimizing risk were the only objective.
If you have say a 10 year need for cash, and you are holding 5 year CDs, then you have reinvestment risk. You can avoid (reduce) that risk by holding bond funds (of longer term to maturity bonds).
As discussed above, a 10-year Treasury, either nominal or real, is the riskless asset for a 10-year liability, either nominal or real. Any typical bond fund introduces some risk, since the fund does not mature, and hence can't be used to precisely match a 10-year liability. There is wide variation in the 10-year returns of intermediate-term bond funds relative to the initial yield--+/-50 basis points annualized is common, and it can be +/- 1 percentage point or more, which adds up to a lot over 10 years.
You can mitigate this by matching the duration of your bond funds to the duration of your liabilities, but this requires frequently exchanging shares from a longer-term fund to a shorter-term fund to match the decreasing duration of the liabilities. This approach is used by some forum members, using long-term and short-term TIPS funds in lieu of a TIPS ladder, while others stick with the ladder since it can be more reliable in matching liabilities precisely, and less maintenance is required.
The problem with using TIPS funds or ladders is the low yields. If you believe low yields are here to stay, or you simply don't want to take any risk in return for the prospect of higher returns, then a duration-matched TIPS ladder or set of funds is the way to go. Higher future yields (i.e., the term risk shows up) in this case are realized as opportunity cost--you would have been able to have even more money by rolling shorter-duration TIPS or sticking with shorter-duration TIPS funds--but if safety is your only concern, then you accept this as the price for safety. You're not taking any significant reinvestment risk, and you have decided that the term risk is irrelevant to your needs.
But some of us with investment horizons of much longer than 5-7 years prefer to take some reinvestment risk while keeping term risk to a minimum in return for a large yield premium over Treasuries. This is what CDs--especially really good direct CDs--provide. Expected inflation is built into the yields of nominal Treasuries (other than at the very short end in recent years), and I'm willing to take some unexpected inflation risk (and reinvestment risk) in return for a yield premium of 100 basis points or more along with very low term risk.
So I'm making what I consider to be a fairly low risk bet that I'll do better with my 5-7 year CDs than I would with a 20-30 year TIPS ladder. I essentially get intermediate-term yields with short-term risk, so get the benefit of being able to quickly roll to higher yields if they occur (as with short-term nominal Treasuries), but without giving up the higher yields of intermediate-term Treasuries. I think it's a pretty good bet, given the 100 bps advantage over institutional investors making a similar bet.
The yield curve is traditionally upward sloping and certainly Bill Gross at Pimco built a career around that "sweet spot" of 7 years. However the yield curve is now unusually flat (has been for a number of years). It's not clear the strategy still works.
Not sure your premise is correct, but let's look at some actual data to check. Here is the historical yield spread between the 10-year and 2-year Treasuries, which is a common metric of yield curve steepness:
Although the yield curve has been flattening over the last few years, it was at one of its steeper points as recently as December 2013, and the recent period of flattening doesn't look particularly unusual, nor is the current curve particularly flat compared to many previous periods. Of course is also is not particularly steep.
Also, I think you may have your thinking backwards. The strategy I'm familiar with, as explained by Larry Swedroe, for example, is to extend maturity when the yield curve is steep (but still not much beyond 10 years), since that's when the additional term risk is most likely to be rewarded, but otherwise stick with shorter maturities (perhaps closer to 5-7 years max). Since the yield curve is not now particularly steep, I'd think this would be even more of an argument to keep maturities relatively short (unless you want a strict, liability matching fixed-income portfolio).
Conversely, interest rates have gone *down* rather than up, contrary to (most of our) expectations. At which point, the reinvestment risk has been higher than we expected. We can't bank on "normal circumstances" returning.
Well, it depends on exactly what time period we're considering as well as what maturities. Let's look at some data. First let's look at the 5-year and 10-year Treasury yields over the last five years--a fairly common time period to consider, and one that's relevant if we're talking about 5-year CDs.
We see that the 10-year yield is higher now than five years ago, but certainly lower than it's highs in 2013/2014. The 5-year yield also is significantly higher than five years ago, and although not at a peak, it's also higher than it was during most of the last five years. So it looks like term risk has shown up more than reinvestment risk over the last five years.
As a personal datapoint, one of the first direct CDs I bought was near the end of 2010--a 5-year CD with an APY of about 2.75%. The last CD I bought late last year was also a 5-year CD with an APY of about 2.75%. Along the way I bought a number of 5-year CDs at about 2%, but my more recent purchases have all been at higher yields. So for me personally, reinvestment risk has not shown up over the last 6-7 years.
But this is all backward looking. What matters to us in making investment decisions is ex-ante risk, not ex-post risk. I don't see anything that much different looking forward now than I did 6-7 years ago. Yields are historically low, and CDs offer good yield premiums over Treasuries--especially if you are patient and jump on the good deals that seem to come along on a fairly regular but unpredictable basis. The 5-year breakeven inflation rate is almost exactly what it was five years ago, so inflation expectations remain muted.