(AP) -- Stocks recovered from an early slide on Wall Street and closed broadly higher Friday, notching their biggest weekly gain in 16 months.
The S&P 500 rose for the fourth straight day, adding 1.2% to a streak that included back-to-back days with gains of 2%. The Dow Jones Industrial Average rose 0.8%, while the Nasdaq composite rose 2%. The three indexes each had their best week since November 2020.
This week's market rally came as Wall Street drew encouragement from the Federal Reserve, which announced its first interest rate hike since 2018 and signaled several more to come. The move, which had been widely expected for months by the market, sends a message that the central bank is focused on fighting the highest inflation in decades. Fed Chair Jerome Powell also stressed confidence that the economy is strong enough to withstand higher interest rates.
The Fed's action and economic outlook helped give markets a better sense of what to expect going forward, said Bill Northey, senior investment director at U.S. Bank Wealth Management.
"This resulted, to a certain extent, in a relief in the stock market that has ridden that over the course of the past several days," he said.
Stocks also got a boost as the price of U.S. crude oil, which briefly topped $130 a barrel last week amid concerns that the conflict in Ukraine will squeeze energy markets, eased briefly below $94 a barrel on Wednesday and has since been hovering below $110 a barrel.
The S&P 500 rose 51.45 points to 4,463.12. The Dow gained 274.l7 points to 34,754.93, and the Nasdaq added 279.06 points to 13,893.84.
Smaller company stocks also gained ground. The Russell 2000 index rose 21.12 points, or 1%, to 2,086.14.
The broader market has been volatile over the last few weeks as investors consider a number of concerns including inflation and Russia's invasion of Ukraine. Major indexes are down for the year in a sharp reversal from solid gains over the last several years.
"That macro picture is not going to change, it's going to take weeks and months," said Jason Draho, head of asset allocation for the Americas at UBS Global Wealth Management. "Nothing in the past few days is going to alter that."
Russia's invasion Ukraine has weighed heavily on markets as investors try to gauge how the conflict could impact global economic growth. Markets in Europe have been particularly sensitive to the war and were mostly lower on Friday. Oil prices have been extremely volatile and U.S. benchmark crude oil remains above $100. Energy prices were relatively stable on Friday, with U.S. crude oil settling at $104.70 per barrel and Brent crude, the international standard, settling at $107.93 per barrel.
The ongoing war in Ukraine continues to drive sentiment after Ukrainian President Volodymyr Zelenskyy called for more help for his country after days of bombardment of civilian sites. Wall Street is also still concerned about rising interest rates, along with surging COVID-19 cases in China and Europe.
High energy prices are only adding to worries about inflation and whether the squeeze on consumers will eventually crimp spending and economic growth.
Rising inflation has prompted central banks to rethink their low interest-rate policies. The Bank of England has been one of the most aggressive, and it raised its key interest rate on Thursday for the third time since December. The Federal Reserve announced a 0.25% increase on its key interest rate on Wednesday. It is the first rate hike since 2018 and is expected to be followed by more this year as the Fed tries to tame inflation.
Friday's gains were broad. Technology and communication stocks, retailers, automakers and other companies that rely on consumer spending helped lift the market. Chipmaker Nvidia climbed 6.8%, Facebook parent Meta rose 4.2% and Tesla rose 3.9%. Only utilities stocks fell.
Bond yields fell. The yield on the 10-year Treasury slipped to 2.14% from 2.19% late Thursday.
Several stocks made big moves after releasing their latest financial results and updates. FedEx fell 4% after its fiscal third-quarter earnings fell short of Wall Street forecasts. U.S. Steel slid 4.6% after giving investors a disappointing profit forecast.