(AP) -- A rough week on Wall Street dominated by worries about a weakening economy ended Friday with a broad rally that gave the market its best day in two weeks.
The S&P 500 rose 1.9%. Despite the gains, the benchmark index still ended with its first weekly loss in the last three. The Dow Jones Industrial Average rose 1% and the Nasdaq composite closed 2.7% higher.
Technology and communication services stocks powered much of the gains as investors cheered another big quarterly surge in Netflix's subscribers. Remarks from a Federal Reserve official also helped build hope among investors that the central bank may decide to slow its pace of interest rate hikes as soon as next month.
The major indexes started the week in the red largely because of worries that the economy may not be able to avoid a scarring recession. Several reports on the economy came in weaker than expected, as the full weight of the Federal Reserve's hikes to interest rates last year start to make their way through the system.
Not long ago, bad news on the economy was often perversely good news for Wall Street. That's because investors took it to mean the Fed may ease up on its rate hikes. But bad news on the economy is increasingly becoming bad news for Wall Street, too, which is worrying more about the prospects of a serious recession.
Making things more complicated, several Fed officials through the week kept pounding the message that they'll likely hike rates further and then hold them there a while to make sure the nation's high inflation is really crushed. Even though inflation has begun to slow, upward pressure remains on it from a still-solid U.S. jobs market and other factors.
Many investors on Wall Street came into this week already forecasting a modest or short recession, but they also were hoping rate cuts by the Fed later this year could mean a rebound for markets. This week's sour economic data and comments from central bankers threaten such forecasts.
But on Friday, Fed Gov. Christopher Waller said he favors just a quarter-point hike on Feb. 1, when the central bank gives its next interest rate policy update. Waller also said that rates are already high enough to be slowing the economy. The remarks could have helped calm rising-rate worries in the market.
"It's important when you hear Federal Reserve members endorsing that," said Quincy Krosby, chief equity strategist for LPL Financial.
Gains for tech-oriented stocks accounted for a big share of the S&P 500's rally Friday. Google's parent company said it was cutting costs by laying off 12,000 workers, and Netflix reported a surge in its number of subscribers.
Netflix's surprising report late Thursday helped set the stage for Friday's rally, because the market had feared the streaming service's latest results would be disappointing and fuel worries about weaker earnings overall, said Jay Hatfield, CEO of Infrastructure Capital Advisors.
"When they started rocketing, then all the Nasdaq started moving, and that moves the S&P and everything else follows," Hatfield said.
Alphabet rose 5.3% after becoming the latest Big Tech company to acknowledge it expanded too quickly in recent years amid a boom created by the pandemic. Netflix jumped 8.5%.
Cruise lines also notched gains. Carnival rose 3.5%, Norwegian Cruise Lines climbed 4.5% and Royal Caribbean added 3.6%.
Also influencing the market on Friday: the expiration of $797 billion in stock-option contracts. That's the largest amount for single stock options since January 2022 and the fourth-largest on record, according to Goldman Sachs.
Treasury yields mostly rose, clawing back drops from earlier in the week driven by worries about a weakening economy. The yield on the 10-year Treasury, which helps set rates for mortgages and other important loans, rose to 3.48% from 3.40% late Thursday.
The two-year yield, which tends to more closely track expectations for Fed action, rose to 4.19% from 4.13%.
All told, the S&P 500 rose 73.76 points to 3,972.61. The Dow gained 330.93 points to 33,375.49. The Nasdaq added 288.17 points to close at 11,140.43.
Small company stocks also notched solid gains. The Russell 2000 index rose 30.99 points, or 1.7%, to finish at 1,867.34.
Stock markets overseas mostly made modest gains.
The Nikkei 225 added 0.6% after Japan reported that its consumer inflation rate hit 4% in December, its highest level in 41 years. The high reading may add to pressures on the Bank of Japan to alter its longstanding policy of keeping its key interest rate at an ultra-low level of minus 0.1%. But economists expect price pressures to ease in coming months as inflation elsewhere declines.