Invest long enough and you'll experience the stock market's ups and downs. For long-term investors, finding quality companies you can invest in through the good and bad times is important to building wealth. For dividend investors, that's especially so. A great business can pay dividends during tough times and keep raising them.

Industrial conglomerate Illinois Tool Works (ITW 0.05%) is a great example. The company has raised its dividend for 60 consecutive years, spanning the last eight recessions! Here is the stock's secret to dividend longevity and why investors can continue banking on future raises.

Many pieces with a common strength

Industrial companies like Illinois Tool Works rely on the broader economy. If a recession occurs and building and manufacturing slow, industrials will likely see slower growth or even lose revenue. You can see below that Illinois Tool Works has seen the occasional bump; revenue declined during recessions in 2001, 2009, and 2020.

But importantly, the drops aren't too steep. Illinois Tool Works has a diverse business with several segments, including automotive, food and beverage, welding, construction, testing, and more. Just as a diverse stock portfolio keeps you afloat when one stock languishes, its diverse revenue streams keep Illinois Tool Works afloat when one segment hits hard times.

ITW Return on Invested Capital Chart

ITW Return on Invested Capital data by YCharts. TTM = trailing 12 months.

Strong management sets the company apart from many of its peers. The company has prudently acquired companies over the years (more than two dozen acquisitions), steadily increasing its return on invested capital (ROIC). In other words, the business has grown and become more efficient at creating profits, a potent combination for stellar investment results.

A strong and battle-tested financial foundation

Financial discipline is another feather in management's cap. I've seen numerous companies harm shareholders with massive debt-fueled acquisitions that put the balance sheet in peril. While Illinois Tool Works leans on debt, it doesn't do so too heavily.

Today, the company has a reasonable debt-to-EBITDA (earnings before interest, taxes, depreciation, and amortization) ratio of 1.8. I personally like to see companies stay under three, and major credit bureaus agree. Illinois Tool Works has an A+ rating from S&P Global, putting it firmly in investment-grade territory.

ITW Cash and Short Term Investments (Quarterly) Chart

ITW Cash and Short-Term Investments (Quarterly) data by YCharts. TTM = trailing 12 months.

That balance sheet is like a financial safety net, ready to buoy the company when hard times hit and protect the company's long-running dividend growth streak. Its $990 million in cash is enough to fund the payout for over six months if cash flow goes to zero overnight.

Responsible dividend growth

Lastly, investors can get a peek at the dividend itself. The stock's dividend yield is currently 2.3%. That won't knock your socks off, but don't forget you're also getting steady raises and the added price appreciation. The stock has returned over 32,000% over its lifetime -- on share price gains alone.

ITW Dividend Chart

ITW Dividend data by YCharts.

The dividend payout ratio is also very solid at 56%. That's calculated with cash flow, meaning the company's profits would need to fall roughly in half to prevent Illinois Tool Works from covering its dividend organically. While no dividend is guaranteed, investors should sleep well at night holding this stock in their portfolio.