The Nasdaq composite index picked up 38.64 points to close at 2,022.96, and the Dow Jones industrial average gained 49.96 to 10,455.63.
More layoffs from Hewlett-Packard, poor quarterly results and expectations from Compaq Computer Wednesday and some grim economic news had dragged technology stocks down earlier in the session, putting a stop to Wednesday's rally. But a surge in buying, led by gains in the semiconductor sector, brought the Nasdaq to a close above the 2,000 mark.
"A lot of people are under the impression that we are pretty close to a bottom. People are beginning to feel the worst is behind us," said Lance Zipper, managing director of equity trading at Brean Murray.
Semiconductor stocks led the gains, with CNET's Semiconductors index up more than 5 percent. Some of the biggest gainers on the index were Broadcom, up $4.07 to $43.10, National Semiconductor, up $3.18 to $30.08, and Cypress Semiconductor, up $3.79 to $26.38. Intel was up 36 cents to $29.78
The morning's economic news showed June durable goods orders were far lower than expected, indicating the economic downturn continues to slow orders for big-ticket items. Orders slid 2 percent in June to $184.11 billion, after a 2.7 percent rise in May, the Commerce Department said. Analysts expected orders to be down just 0.8 percent in June.
Initial jobless claims offered a slightly rosier picture. A report that measures the number of filings for state jobless benefits fell sharply last week, reaching the lowest level since March. The Labor Department said the number of claims fell by 51,000 to 366,000 in the week ended July 21 from a revised 417,000 claims reported a week earlier. Much of the decline was attributed to volatility typical of July, when auto plants and other factories temporarily shut down.
HP, down $1.68 to $24, said it will cut 6,000 jobs and lowered its revenue projections, citing the economic slowdown and weak spending on PCs. The computer maker also said it expects sales to drop 14 percent to 16 percent from a year ago in the quarter ending July 31.
Compaq also took a hit from slowing PC sales. The company reported second-quarter earnings and revenue Wednesday that were in line with lowered forecasts but were down sharply from last year. Shares were up 34 cents to $14.50 after falling earlier in the day.
CNET's PC Hardware index was one of the few indexes to end the day in negative territory, down half of a percent.
Japanese consumer electronics maker Sony also posted a big loss for the latest quarter and slashed its earnings forecast for the full year, citing a slump in its electronics, video game and movie businesses. Shares were off $5.95 to $51.86.
WorldCom Group, the data and Internet business of WorldCom, also reported declines in its second quarter. Net income fell to $110 million, or 4 cents a share, compared with $716 million, or 25 cents a share, a year ago. Shares were up $1.19 to $14.54.
Among other gainers, an upgrade from Salomon Smith Barney gave Vignette an extra kick following Wednesday's news that its second-quarter loss was in line with its lowered outlook and profits would be on the books by the end of the year. Shares in the business software maker were up $1.51, or 22 percent, to $8.35.
The Nasdaq's other impressive gainer was Netegrity, up $5.76, or 27 percent, to $27.13, which also got an upgrade on the heels of its quarterly report. The e-commerce software company said late Wednesday that earnings were 9 cents a share, topping First Call's estimate by a penny. Robertson Stephens also upgraded the stock to "strong buy" from "buy" Thursday.
Among technology bellwethers, Microsoft fell 87 cents to $66.61, Oracle gained 10 cents to $19.36 and Cisco Systems gained 68 cents to $19.38.
Amazon.com rose 82 cents to $12.33, AOL Time Warner rose $1.16 to $44.91 and Yahoo rose 71 cents to $17.58.
Staff and Reuters contributed to this report.