With some frequency, Wall Street professionals use this phrase: “Bad news for the economy is good news for the stock market.” They also use it in reverse, with good news for the economy said to be bad for stocks.

At first glance, whichever way you read it, the line might seem to make little sense. Many people see the economy and the stock market as inextricably linked. In their minds, if the economy is weakening, then surely company profits will suffer, which will end up sending stock prices lower. But that’s not always the case.

Share Your Thoughts

Are there any investing terms that confuse you? Join the conversation below.

It’s only when looking deeper that things become clearer, but even then, there are some subtleties to navigate.

“A little bit of bad news is good for markets,” says

Bruce Monrad,
chairman and portfolio manager at Boston-based mutual-fund company Northeast Investors Trust. It all revolves around the response by the Federal Reserve to economic news. When the news for the economy is bad, such as a sudden unexpected rise in the unemployment rate, then it is less likely that the Fed’s monetary-policy committee will raise the cost of borrowing money—a key variable for both business and consumer finances. That tends to help keep prices for stocks and bonds buoyant, Mr. Monrad says.

But too much bad news is indeed bad for stocks. “The bad news can’t be so bad that it brings into question future earnings,” Mr. Monrad says. For instance, in the early days of the Covid-19 pandemic, news of the global viral outbreak sent markets into a tailspin starting around mid-February 2020 through late March. The S&P 500 index dropped more than 30% over that period, in anticipation of the pandemic’s economic impact. The U.S. economy shrank at an annualized rate of 31% in the second quarter of last year, government statistics show.

Currently, the U.S. economy is looking strong, and that means the Fed is likely drawing closer to raising interest rates. “Fed officials continue to tilt hawkish,” says a recent report from New York-based investment bank Brown Brothers Harriman.

So, that’s good economic news that could be bad for stocks—but maybe not just yet. Interest rates have been so low for so long that it has long been anticipated that the next move in rates will be up. So until rates actually rise, or at least are expected to rise sooner than they are now, the market may continue to climb as the economy improves, some analysts say. And against that backdrop, bad news could lose some of its luster for the market.

“I think we should be in a place where good news is good news,” says

Peter Tchir,
head of global macro strategy at Academy Securities in New York. “Right now, if we get further bad news, we might get markets going down.”

Mr. Constable is a writer in Edinburgh, Scotland. He can be reached at reports@wsj.com.