Shares of Chinese search engine Baidu Inc surged more than 7 percent on Thursday after the company topped Wall Street financial targets, shrugging off concerns that a weakening Chinese economy could hamper its growth.

Baidu said spending by large customers was significantly better than it expected in the third quarter, and the company's forecast of up to 8.6 percent sequential revenue growth in the fourth quarter outpaced the 4.8 percent increase expected by analysts.

We are seeing an acceleration in search and Baidu is also gaining share, which is benefiting them, said Collins Stewart analyst Mayuresh Masurekar.

Baidu should be able to grow strongly despite any slowdown in the China economy because online advertising is gaining share from traditional advertising, it's a secular shift, he said.

Shares of Baidu were up 7.2 percent at $148.50 in after-hours trading on Thursday. Chinese Internet companies Inc and Sina Corp were up more than 4 percent in after-hours trading.

China, with more than 450 million users, is the world's largest Internet market. Yet, with Internet penetration hovering around 30 percent and user sophistication outside the big cities still low, the potential for growth is huge.

Baidu has solidified its position as the dominant search engine in China since Google Inc's decision in 2010 to relocate its search engine to Hong Kong, following a standoff with the Chinese government over Internet censorship.

But Baidu is facing fresh competition from Alibaba Group and Tencent Holdings Ltd, two other Chinese Internet giants.

In August, Baidu suffered a barrage of negative publicity after China Central Television ran programs accusing the company of having lax approval processes on its paid-advertising platform and slamming it for not policing its message-board product Tieba for slanderous remarks.

Analysts said the criticisms did not have a negative material impact on the company and was driven mostly by competitive pressure.

For the third quarter, Baidu reported net income of $295 million, or 84 cents per share. On an adjusted basis, the company earned 86 cents a share in the period.

Analysts on average expected the company to post a profit of 83 cents a share.

Total revenue rose 85 percent to $654.7 million, above its own forecast of $611.1 million to $626.6 million.

ThinkEquity analyst Henry Guo said Baidu's results and revenue forecast show that advertiser spending on Internet search advertising remains healthy. But he said that there are still concerns about what ad spending will look like in 2012 given the economic uncertainty.

He said he hoped Baidu might provide more details on its views of the economy and the year ahead during a conference call slated for later on Thursday.

Baidu said it expects fourth-quarter revenue of $691.4 million to $711.0 million, above analysts' forecasts of $649.5 million, according to Thomson Reuters I/B/E/S.

Shares in Baidu, whose name is taken from an ancient Chinese poem, closed up 6 percent at $138.39 on Nasdaq. They have gained 36 percent so far this year.

(Reporting by Alexei Oreskovic in San Francisco and Soham Chatterjee in Bangalore, with additional reporting by Melanie Lee in Shanghai; Editing by Gary Hill)