NEW YORK — Weak earnings guidance from Wal-Mart and a couple of tepid reports on the economy pushed stocks lower on Wednesday.

Wal-Mart logged its biggest one-day decline in almost three decades after the retailer stunned investors with an announcement that it expects its profit to fall as it works to fend off intensifying competition. JPMorgan led financial stocks lower after the lender’s third-quarter earnings fell short of analysts’ expectations.

A rally for stocks has stalled this week as worries about weakening global growth have resurfaced. A Federal Reserve report on Wednesday showed that factory output was sluggish in the late summer, in part because of the strong dollar. A separate report on retail sales indicated that Americans are still spending cautiously.

After a sharp summer sell-off in stocks that was followed by an early October rebound, investors are split as to what comes next for the market. Some are expecting a strong fourth quarter, while others think that there could be more selling to come.

“I’m pretty much in the bearish camp,” said Ken Winans, president of Winans Investments, an investment advisory and research firm. “The fear has come back in.”

The Standard & Poor’s 500 index closed down 9.45 points, or 0.5 percent, to 1,994.24. The Dow Jones industrial average fell 157.14 points, or 0.9 percent, to 16,924.75. The Nasdaq composite fell 13.76 points, or 0.3 percent, to 4,782.85.

Wal-Mart was the biggest decliner in the S&P 500 and also dragged the Dow lower.

The retailer forecast that sales for its full fiscal year would be flat as the company was hurt by unfavorable currency exchange rates. Wal-Mart had previously forecast sales growth of 1 to 2 percent. For its next fiscal year, it said profit could fall by as much as 12 percent.

The stock slumped $6.70, or 10 percent, to $60.03, its worst one-day decline since January 1988.

Investors were also assessing earnings reports from three big banks.

Bank of America’s stock gained after reporting its results, but shares of JPMorgan and Wells Fargo declined.