NEW YORK ( MainStreet) — Most investors know rising interest rates can undermine bond prices, but just how bad can it be? With rates likely to drift up this year, it's important to know.

While bonds do indeed perform poorly in this kind of environment, the damage isn't always as bad as many investors expect, according to a study by Morningstar , the market-data firm.

"The risk of rising rates is real and could be costly if the magnitude of the move proves large," Morningstar cautions. "And even if rates stay steady, bonds no longer benefit from the tailwind of falling yields, which spurred impressive gains since the 1980s. Nevertheless, we don't believe investors should jettison them from portfolios altogether."

The general effect of rising rates is easy to understand. If you paid $1,000 for a bond yielding 3%, it would pay you $30 a year. If, a year later, new bonds selling for $1,000 were to yield 6%, no one would pay the full $1,000 for your older bond. Its price would fall to $500, so its $30 annual payment would equal the same 6% paid by new bonds.

That would be pretty devastating, but in real life other factors reduce the damage. For one thing, the possibility of higher rates may be worked into the price of a bond when you or your mutual fund buys it, so that the reality of higher rates has less impact later. Also, those $30 coupon payments could be reinvested in newer bonds with higher yields.

For a real-life look, Morningstar examined the performance from 1946 through last September of the Ibbotson Associates SBBI Intermediate-Term Government Bond Index , a gauge of the broad government bond market. The study looked at the index's total return in periods when rates rose by at least 10 basis points, or 0.1 percentage points.

There were 64 such periods, with rates rising by 16 to 468 basis points over two to 21 months. Overall, the index returned 22 basis points during these periods. While nothing to brag about, that's "hardly the bloodbath some might have expected," Morningstar reports.

The largest loss was 5.53% from September 1993 to December 1994, when the rates rose by 297 basis points. At the other extreme was a 5.87% gain from November 1976 to June 1978, as rates climbed by 250 basis points. For all 64 periods, the median after-inflation return was a loss of 1.49%.

A closer look showed that "real" yields, which subtract the loss to inflation, are especially hard hit when rates are low at the start of the period and inflation is unusually high in the year before rates begin to rise. When rates are high at the start, returns are not hurt as badly regardless of what inflation does. This makes sense, because higher yields provide a bigger cushion for absorbing the damage from inflation.