There's a reason municipal bonds have long appealed to investors at all stages of life. Unlike the interest paid on corporate bonds, municipal bond interest is always tax-exempt at the federal level. Better yet, if you buy municipal bonds issued by your home state, you get to collect those payments free of state and local taxes, as well.

But it's not just tax-free interest payments that draw investors to municipal bonds. Those with a strong aversion to risk might take comfort in the fact that municipal bonds sport historically low default rates. In fact, municipal bonds are actually 50 to 100 times less likely to default on their obligations than corporate bonds with the same ratings.

But lately, some shake-ups in the market have called the safety of municipal bonds into question. First, there was Puerto Rico, which, after years of plummeting bond prices and financial struggles, declared its own form of bankruptcy in early May. And now, in a less-than-positive turn of events, Illinois just had its bond rating downgraded by both Moody's and S&P -- agencies whose ratings carry a ton of weight. The result? Illinois now has the lowest ranking on record for a U.S. state, and its bondholders risk suffering the same fate that so many Puerto Rico investors are currently bemoaning.

Chicago skyline

IMAGE SOURCE: GETTY IMAGES.

Furthermore, this new source of upheaval in the municipal bond market raises the question: Are these bonds really as solid an investment as we're told to believe? Or are we better off putting our money elsewhere?

How Illinois got here

Similar to Puerto Rico, Illinois reached the point it's currently at by failing to implement a budget that addresses the government's long-standing deficits. For years, the state has been plagued with underfunded pensions and unpaid bills that equal roughly 40% of its operating budget. And while Illinois hasn't reached junk bond territory just yet, it's currently just one notch above that unwanted benchmark. This means that if things don't turn around soon, the state is likely to lose its investment-grade status.

If Illinois does wind up hitting junk status, it would clearly spell trouble for its bondholders. The extent of that trouble is yet to be determined, but at a minimum, we can expect bond prices to fall, thus leaving investors with limited liquidity and exposing them to untold losses.

This has happened before

If you've been following the municipal bond market closely, you're probably experiencing an eerie sense of deja vu. In fact, last month, the big story was Puerto Rico and the extent to which its unprecedented bankruptcy filing might ultimately hurt bondholders. All told, approximately 15% of the island's debt is held by U.S. workers who invested in Puerto Rico in the hopes of building their retirement nest eggs.

Of course, Puerto Rico bonds were particularly appealing back in the day, not just because of their impressive yields, but because of their automatic triple tax-exempt status. Illinois, on the other hand, is a completely different story. But while there may be fewer individual bondholders who actually wind up suffering financially if things in Illinois take a turn for the worse, this news should serve as a warning that muni bonds aren't always safe. As is the case with corporate bonds, municipal bonds run the gamut from highly-rated issuers to those teetering on the edge of economic ruin -- so buyers ought to beware.

Furthermore, if you're a holder of municipal bonds, be sure to track your investments, regardless of how high a rating your bonds held back when you first bought them. Remember, folks who invested in Puerto Rico didn't do so to get a piece of the junk bond action; but because so many holders of Puerto Rico debt failed to keep tabs on the situation as it unfolded, they're now stuck holding investments with questionable value.

Finally, if you're thinking that now's a good time to buy up some Illinois debt on the cheap, think again. While there are professionals -- notably, hedge fund managers and the like -- who make a killing by investing in junk bonds, such bonds are not suited for the typical investor. And while Illinois hasn't reached junk status just yet, based on its track record and what we've seen elsewhere, it may be only a matter of time.