Stocks rose on Tuesday as traders navigated one of the busiest weeks of corporate earnings season, and monitored the latest moves in interest rates.
The Dow Jones Industrial Average gained 499.51 points, or 1.45%, to close at 34,911.20. The S&P 500 rose 1.61% to 4,462.21, and the Nasdaq Composite surged 2.15% to 13,619.66.
Stocks have been under pressure recently, with the S&P 500 falling for two straight weeks, but investors were adding risk assets on Tuesday. The small and mid-cap heavy Russell 2000 rose 2.1%.
"Both sentiment and positioning are now too bearish, in our view. While we slightly reduced our record equity allocation ... we remain constructive on equities and think that a near-term rally is likely, particularly in small-cap and high-beta market segments," JPMorgan's Marko Kolanovic said in a note to clients.
Bank stocks outperformed as rates moved higher and regional and mid-sized banks reported earnings. Citizens Financial, which beat first-quarter estimates on the top and bottom lines on Tuesday morning, jumped 6.8%. JPMorgan rose more than 2%.
Some heavy hitters in the tech and media industries also rose on Tuesday. Shares of Disney and Netflix climbed 3.2%. Microsoft and Alphabet rose 1.7% and 1.8%, respectively.
The gains for stocks came despite a further climb in interest rates, which may be a sign that investors shouldn't trust Tuesday's rally, said Andrew Smith, chief investment strategist at Delos Capital Advisors.
"I think a lot of it has to do with those defensive names that did so well, you're just kind of getting this rotation. But tech up as much it is today with real yields moving much higher, that's not a normal occurrence," Smith said.
Earnings reports drove individual stock moves Tuesday. Johnson & Johnson reported mixed quarterly results, with its earnings per share topping earnings expectations while revenue missed analyst estimates. Its shares rose 3%, however, boosting the Dow.
Hasbro shares added about 5% despite the toy company posting a weaker-than-expected profit for the previous quarter. Its revenue was in line with estimates. Travelers Companies dropped 4.9% and Lockheed Martin shares lost 1.6% after posting mixed results.
On the data front, housing starts and building permits in March came in above expectations, according to estimates from Dow Jones. That appeared to boost homebuilder stocks, with D.R. Horton gaining 3.9%.
"So far the economic data has been holding up fairly well, so there is some underlying strength even though recession worries are growing and voices about a growth slowdown are getting louder," said Angelo Kourkafas, investment strategist at Edward Jones.
The energy market may have helped trader sentiment on Tuesday, with prices for oil and natural gas both declining sharply. Kourkafas said the declines may have provided "some relief" for investors worried about inflation.
Elsewhere, travel stocks also performed well in the wake of the mask mandate for airlines being lifted following a court decision Monday. Shares of American Airlines gained more than 5%, while United climbed 4.5%.
Traders also kept an eye on the bond market, where the 10-year Treasury yield hit 2.94%, its highest level since 2018. Expectations for Fed hikes have risen sharply in recent months, though the central bank has said it will be data dependent in deciding how it will hike rates throughout the year.
The concern about the Fed's next steps have caused high volatility in the bond market as well, which appears to have weighed on stocks in recent weeks. St. Louis Fed president James Bullard told CNBC's Steve Liesman on Monday that "quite a bit has been priced in" in terms of Fed actions.
— CNBC's Tanaya Macheel contributed to this report.