As it consumed billions of dollars of cash as part of a failed makeover strategy during 2012 and 2013, J.C. Penney (JCPN.Q) was slammed with numerous debt rating downgrades. This increased J.C. Penney's cost of issuing debt just as it needed to raise a lot of cash.

Strategy missteps in 2012 and 2013 hurt J.C. Penney's credit rating. Photo: The Motley Fool.

However, J.C. Penney has stabilized its financial performance since 2014. It has produced free cash flow in each of the last two years and expects free cash flow to rise again in 2016. This has allowed it to start paying down debt. Credit rating agencies are starting to take notice. Last week, S&P upgraded J.C. Penney's rating by two notches, from CCC+ to B.

J.C. Penney's credit rating plunges
Just five years ago, J.C. Penney had an investment-grade credit rating from Fitch Ratings -- one of the three major credit rating agencies -- and was one notch below investment grade at the other two.

However, the company implemented an aggressive $900 million share repurchase program in 2011. A year later, under new CEO Ron Johnson, it embarked on a new pricing and merchandise strategy that failed spectacularly. The combination of falling sales, weak profit margins, and heavy capital spending caused J.C. Penney to burn through more than $3.6 billion of cash in a two-year span.

Thus, by early 2014, the best credit rating J.C. Penney could muster was a dismal CCC+ -- seven notches below investment grade -- with a stable outlook, from S&P. The only positive thing that S&P could say about J.C. Penney at the time was that it didn't "see a clear path to default" for the struggling department store.

Slow gains
Since mid-2013, J.C. Penney has gradually abandoned its everyday low pricing experiment and returned to its previous strategy of big initial markups, frequent sales, and ubiquitous coupons. It has also doubled down on merchandise initiatives that are working (like its Sephora boutiques) while dumping those that didn't resonate with customers.

This has driven fairly steady mid-single digit comparable store sales growth since late 2013. Meanwhile, J.C. Penney has slashed its operating expenses by a quarter in the past five years and it has cut back significantly on capital expenditures, boosting free cash flow.

Furthermore, as J.C. Penney has gained access to more credit, it has been able to carry less cash. As a result, it has been able to reduce its debt burden from $5.6 billion in early 2014 to around $4.8 billion today.

J.C. Penney's financial performance has been improving since late 2013. Photo: The Motley Fool.

These balance sheet improvements and J.C. Penney's recovering profitability finally convinced S&P to upgrade its credit rating last Wednesday, from CCC+ to B. S&P also stated that there was a one-third chance that it would upgrade J.C. Penney's credit rating again within the next year.

Even after last week's two-notch upgrade, J.C. Penney's corporate credit rating is still far below where it stood five years ago. But at least it's making progress.

A higher credit rating is good for shareholders, too
Credit ratings matter most to J.C. Penney's creditors. A higher credit rating means that there is probably a lower chance that the company will default on its debt. All else equal, that should cause J.C. Penney's bonds to rise in value.

From a shareholder perspective, J.C. Penney's credit rating is important because the company has nearly $2.5 billion of debt maturing in 2018. While the company may be able to pay off some of that amount from its free cash flow and the proceeds from asset sales, it will need to refinance a large chunk of that sum.

Credit ratings aren't the only thing that bond investors pay attention to, but they are certainly important. The higher J.C. Penney's credit rating when it comes time to refinance its 2018 debt maturities, the lower its interest rate will be going forward. Ultimately, that will mean more cash in shareholders' pockets.