Last week, J.C. Penney (JCPN.Q) completed the refinancing of a massive $2.25 billion term loan dating from the dark days of 2013, when the company was hemorrhaging cash. By refinancing the loan, J.C. Penney expects to reduce its annual interest expense by $24 million.

If it had waited a little longer to refinance, there's a good chance that J.C. Penney could have locked in even more interest savings. The company's decision to refinance the full outstanding balance of $2.19 billion two years early shows a commitment to making the "safe" choice rather than taking on extra risk in pursuit of greater gains. Given the turbulent state of the retail industry today, that's probably wise.

Reducing financial risk

The legacy of J.C. Penney's terrible financial performance a few years ago is a heavy debt load. At the end of 2013, the company had $5.6 billion of debt. In the past two years, the company has focused on using excess cash and its modest free cash flow to pay down debt. By the end of last quarter, J.C. Penney had reduced its outstanding debt to $4.7 billion.

J.C. Penney has started to pay down its massive debt load. Image source: The Motley Fool.

As of earlier this year, $2.45 billion of that debt was scheduled to mature in 2018 -- more than half of the total. This included most of the principal of the $2.25 billion term loan as well as $300 million in senior notes.

It's risky for any company to have a large amount of debt maturing in any one year. A financial market downturn can make it expensive (or even impossible) to refinance a large debt maturity. This risk is magnified for a company in the midst of a turnaround like J.C. Penney. A stumble in its turnaround progress around the time of a large debt maturity could prove fatal.

This is the fundamental reason why J.C. Penney decided to refinance its term loan now. Interest rates remain relatively low and J.C. Penney's credit metrics have started to improve, so it was able to extend the maturity of its term loan to 2023 while reducing its annual interest expense.

Could J.C. Penney have done better?

I was somewhat surprised that J.C. Penney opted to refinance the term loan now rather than holding off for a while. First, the company will have to take a $34 million non-cash charge this quarter related to the refinancing. The longer it had waited to refinance, the lower this charge would have been.

Second, J.C. Penney's credit metrics have been improving rapidly for the past two years, and the company expects that progress to continue for the foreseeable future. J.C. Penney will probably be more creditworthy a year from now than it is today. That could have allowed it to secure an even lower interest rate.

However, waiting until next year to refinance would have meant accepting the risk of something going wrong between now and then. Macy's (M -1.52%) recent performance demonstrates the danger of adopting aggressive financial policies like that.

Several years ago, Macy's set a target range for its debt relative to its annual earnings before interest, taxes, depreciation and amortization. As its earnings soared between 2012 and 2014, Macy's spent an increasing amount on share repurchases at ever higher prices, even incurring new debt to fund those buybacks.

M Chart

Macy's Buybacks vs. Stock Performance data by YCharts.

As Macy's sales and earnings started to slide last year, the stock plunged by more than half. The stock price plunge was undoubtedly aggravated by Macy's aggressive financial policies, which caused net debt to rise from $4.9 billion at the end of 2013 to $6.5 billion by the end of 2015.

The value of safety

By refinancing its term loan and paying down some of its other debt, J.C. Penney has started to make significant headway in reducing its annual interest expense. However, some of the interest savings will be offset by the $34 million write-off stemming from the refinancing. Furthermore, J.C. Penney may have been able to reduce its interest rate even further if it had waited another year to refinance.

That said, it's possible that interest rates could rise in the next year. Additionally, the recent "Brexit" vote has created even more uncertainty about retail sales trends, increasing the risk of J.C. Penney missing its sales targets.

In this context, the company's decision to play it safe by reducing its near-term debt maturities seems like a very prudent move. J.C. Penney can't afford a Macy's-like mistake of adopting riskier financial policies just as sales growth comes under pressure.