By Joe Wallace and Michael Wursthorn

U.S. stocks, from health care to technology to financials, rallied Thursday, giving major indexes a boost as the euphoria in some of the most overheated segments of the market showed signs of easing.

All 11 sectors of the S&P 500 traded higher, led by health care, industrial and financial stocks. Some of the gains followed better-than-expected earnings reports from companies such as American Airlines Group, but much of the green that flashed across the stock market was attributed to opportunistic investors willing to pounce on stocks following their biggest pullback since October, analysts said.

The Dow Jones Industrial Average rose 301 points, or 1%, to 30604 as of the 4 p.m. close of trading in New York. The S&P 500 added 1%. The Nasdaq Composite also traded higher, gaining about 0.5%. Those gains helped ease losses indexes have suffered throughout the week.

At the same time, the euphoria surrounding stocks like GameStop and AMC Entertainment showed signs of abating. GameStop shares have fluctuated and were recently down nearly 40%, while AMC stock slumped more than 50%. The slides coincided with decisions by brokerages like Robinhood Markets and Interactive Brokers Group to restrict the trading of GameStop, AMC and other high-flying stocks.

Trading around those two stocks and others had captured the attention of Wall Street and Main Street alike. At its core, internet day traders pitted themselves against short-selling hedge funds, driving a parabolic rise in stocks like GameStop. Trading appeared to hit a fevered pitch Wednesday, as more shares changed hands that day than any other since mid-2019.

The broader stumble in stocks most of the week followed a strong start to the year that some investors say had pushed share prices beyond levels justified by corporate fundamentals and created pockets of excessive enthusiasm within segments of the stock market, including in GameStop shares.

Analysts are urging investors to look past those one-off situations and focus on earnings, which have been mostly upbeat. Nearly a third of the S&P 500 has reported results so far, and about 81% have topped analyst's forecasts, according to FactSet data.

"While the behavior of some market participants is reminiscent of historical stock market bubbles," said Mark Haefele, chief investment officer of global wealth management at UBS Group AG, "we don't believe the market as a whole is in a bubble."

Mr. Haefele and other analysts continue to make the argument that stocks continue to trade at attractive valuations relative to interest rates and bond yields, which remain subdued. UBS believes the S&P 500 could eventually close at 4000 by the end of the year, about a 5% gain from current levels.

Quarterly earnings appeared to factor into some of the biggest moves in the stock market on Thursday.

Shares of American Airlines jumped 11% after the airliner reported a narrower loss than what analysts had predicted. Other travel stocks rallied, including United Airlines, up 7.8%, and Carnival, which added 6.2%.

Comcast stock added 7.7% after the company reported growth in its broadband business, pushing results above analysts' forecasts.

Shares of Apple, meanwhile, fell about 2% after the iPhone maker reported its most profitable three months on record but didn't provide specific revenue guidance for the current quarter.

Tesla dropped 2.2% after the electric-vehicle maker -- shares of which have soared in recent months -- posted its first full-year profit but missed Wall Street's expectations.

Visa and Mondelez International are scheduled to publish results after the close. Both were recently trading higher.

"It is nerve-racking," said Remi Olu-Pitan, a fund manager at Schroders, referring to the big moves in stocks fueled by day traders swapping tips online.

"You will see more violent pullbacks," she said, adding that Europe's slow progress on vaccines and Covid-19 restrictions in major economies were also weighing on stocks.

Meanwhile, investors parsed the latest releases of economic data. Weekly applications for unemployment benefits, tracked as an indicator of the health of the labor market, declined last week but remained elevated at 847,000. Separate figures showed gross-domestic product, a broad gauge of the value of goods and services produced in the economy, grew at a 4% annual rate in the final quarter of 2020, slightly slower than economists had expected.

This data came after the Federal Reserve maintained its easy money policies Wednesday, saying that business activity has softened with the resurgence of Covid-19 cases.

In one sign of rising risk aversion, the yield on the benchmark 10-year U.S. Treasury note dropped below 1% for the first time since Jan. 6, before climbing back to 1.047%, according to Tradeweb. Bond yields fall as prices rise. Falling yields are often an indicator that investors see the economic outlook weakening.

Stocks traded mostly lower overseas. The pan-continental Stoxx Europe 600 rose 0.1%. Hong Kong's Hang Seng dropped 2.6%, the Shanghai Composite Index fell 1.9% and Japan's Nikkei 225 declined 1.5%.

Caitlin Ostroff

contributed to this article.

Write to Joe Wallace at Joe.Wallace@wsj.com and Michael Wursthorn at Michael.Wursthorn@wsj.com

(END) Dow Jones Newswires

01-28-21 1616ET