Updated

Stocks rose late Thursday, recovering from early losses triggered by a series of deadly explosions that rocked London and killed at least 37 people. All three major indexes opened down nearly 1 percent but slowly returned to positive territory during the session.

A perception that the London attacks would have limited impact on the global economic outlook helped markets as U.S. investors noted that stocks also bounced back after the train bombings in Madrid last year.

Based on the latest available data, the blue-chip Dow Jones industrial average (search) rose 31.61 points, or 0.31 percent, to finish at 10,302.29. The broad Standard & Poor's 500 Index (search) advanced 2.92 points, or 0.24 percent, to end at 1,197.86. The tech-laced Nasdaq Composite Index (search) gained 7.01 points, or 0.34 percent, to close at 2,075.66.

Traders said the timing of the London attacks, several hours before the start of trading in New York, allowed investors to overcome any knee-jerk reactions to the news. Jay Suskind, head trader at Ryan Beck & Co., noted that buy orders quickly entered the market as stocks sold off at the opening bell.

"Unfortunately, this is the world we live in now. Five years ago, the market would have been down much more. Now, we see it as a buying opportunity," Suskind said. "There's no panic."

Unlike the Sept. 11, 2001, attacks on the United States — which closed U.S. equities markets for four days — the London events didn't knock out trading systems.

"Major markets already have built in a terror premium," said Joseph Battipaglia, chief investment officer at Ryan, Beck & Co., of Yardley, Pennsylvania. "When an incident occurs, unless it's of catastrophic proportions, the markets take it in stride."

Crude oil futures fell sharply after the Energy Department reported a drawdown of 3.6 million barrels of crude from the nation's petroleum reserves. Gasoline reserves also fell, but heating oil and other distillate reserves were up sharply. A barrel of light crude settled at $60.73 a barrel, down 55 cents on the New York Mercantile Exchange (search).

Shares of insurance companies and airlines, both sensitive to disasters, remained mostly lower for the day. Investors nerves' were frayed by continuing warnings through the day, including a scare following the discovery of a suspicious package near London's Victoria station.

Delta Air Lines (DAL) fell 2.9 percent to $3.38 after earlier falling as low as $3.24. General Electric Co. (GE), a component of the blue-chip Dow Jones Industrial Average, fell nearly 1 percent to $34.05.

Technology shares were also lower, with Intel Corp. (INTC) falling nearly 1 percent to $26.34, and Microsoft Corp. (MSFT) dropping nearly 1 percent to $24.55.

But shares of security and video surveillance companies surged. Internet video company IPIX Corp. (IPIX) surged 19.7 percent, or 54 cents, to $3.28 and bomb-detection equipment maker Isonics Corp. (ISON) jumped 5.6 percent, or 17 cents, to $3.20, both in Nasdaq trading.

The stock of American International Group (AIG), the world's largest insurer and one of the 30 stocks in the blue-chip Dow average, was up 0.5 percent, or 32 cents, at $59.47, recovering from a session low of $58.52. And the stock of insurer Chubb Corp. was up 0.2 percent at $85.62, off a session low of $84.37.

Shares of Gap Inc. (GPS) were up 3.8 percent, or 76 cents, at $20.99 and Target Corp. (TGT) advanced 1.6 percent, or 86 cents, to $56.42. Both S&P 500 component companies trade on the NYSE.

By the end of the day, investors were turning their attention to earnings news from Alcoa Inc. (AA), which reported results that topped Wall Street expectations. Shares of Alcoa, the first Dow component to report quarterly results, were up 3.9 percent at $27.10 after the bell on the Inet electronic brokerage system, above their $26.09 NYSE close.

Investors are looking ahead to figures due Friday that are expected to show June U.S. non-farm payrolls grew 188,500, according to economists polled by Reuters.

European Central Bank President Jean-Claude Trichet (search) said he had discussed the situation with Federal Reserve Chairman Alan Greenspan (search) and Bank of England head Mervyn King and concluded financial systems were working normally. "We are alert, we are vigilant," he told a news conference. Treasury Secretary John Snow (search) added that the Bush Administration would keep close tabs on global markets.

The Nasdaq Stock Market said it increased security efforts at its New York headquarters and its data center in Connecticut. A New York Stock Exchange spokesman said the Big Board does not comment on its security measures.

In Europe, equities pared losses after plunging as much as 4 percent in their biggest fall in nearly three years as a series of deadly explosions rocked London and killed several people.

Britain's FTSE 100 fell by as much as 4 percent, but recovered somewhat and closed 1.36 percent lower. France's CAC-40 fell 4.5 percent before recovering to a loss of 1.39 percent for the session, and Germany's DAX index was down 1.85 percent.

"American investors are not only reacting emotionally, they're trying to figure things out, trying to determine the economic impact of what happened," said Ken Tower, chief market strategist for Schwab's CyberTrader. "When you're not at the epicenter, that's easier to do. There were many more cooler heads outside of New York after 9/11, after all."

European travel, hotel and leisure shares bore the brunt of the sell-off. British Airways shed 4.2 percent, and Burberry fell 2.9 percent. Insurers such as Allianz and Axa slid nearly 3 percent, and reinsurers, which assume risks that are too big or too volatile for insurers to keep on their own balance sheets, were also pounded.

Trading was heavy, with 1.52 billion shares changing hands on the New York Stock Exchange, above the 1.46 billion daily average for last year. About 1.62 billion shares were traded on Nasdaq, below the 1.81 billion daily average last year.

The number of shares increasing in value exceeded the number declining in value by a ratio of about 9 to 7 on the NYSE. Advancers slightly outnumbered decliners on the Nasdaq, with 1,526 stocks rising and 1,482 falling.

The Russell 2000 index of smaller companies was up 1.03, or 0.2 percent, at 649.30.

In other overseas markets, Japan's Nikkei stock average fell 0.12 percent. The markets there closed before the London attacks occurred.

Reuters and the Associated Press contributed to this report.