Stocks fell on Thursday after three days of gains as earnings from JPMorgan and soft economic data from China reinforced worries about a slowing global economy.

China's trade surplus narrowed for a second straight month in September as both imports and exports were lower than expected, pointing to cooling domestic and global economic demand.

JPMorgan Chase & Co , the second-largest U.S. bank, slumped 6.2 percent to $31.16 and was the biggest drag on the Dow after reporting the drop in net.

The first major U.S. bank to announce earnings said profits were hurt as the European debt crisis pushed investment banking clients to the sidelines. The KBW Bank index <.BKX> shed 4.5 percent while Bank of America Corp lost 5.8 percent to $6.20.

People have known banks were going to struggle in this environment, but I'm still optimistic earnings will largely come in at lowered expectations, said Mark Luschini, chief investment strategist at Janney Montgomery Scott in Philadelphia.

With the S&P rising six out of the last seven sessions, the index has run up 11.4 percent from an intraday low hit last Tuesday. It had its largest seven-day rally since March 2009 on growing optimism European leaders were making progress in tackling the region's debt problems.

We've had a pretty decent rally from the nadir, but we can't continue to go straight up in the absence of anything definite from Europe, Luschini said. We've been rising on hope rather than anything tangible.

The Dow Jones industrial average <.DJI> was down 121.92 points, or 1.06 percent, at 11,396.93. The Standard & Poor's 500 Index <.SPX> was down 15.21 points, or 1.26 percent, at 1,192.04. The Nasdaq Composite Index <.IXIC> was down 14.02 points, or 0.54 percent, at 2,590.71.

Vertex Pharmaceuticals Inc was the top gainer on the Nasdaq 100 <.NDX>, climbing 6.9 percent to $43.02 after IMS Health said it was revising estimates of the number of prescriptions written in late September for Vertex's hepatitis C drug.

In U.S. economic data, new claims for jobless benefits were little changed last week and the trade deficit narrowed marginally in August, indicating a modest improvement in the economy.

Google is reporting third-quarter earnings after the close and investors will be looking to see how the slowing economy is impacting its advertising business. Earnings are seen rising 14.5 percent year-over-year at the Internet company, while revenue is seen up 31.7 percent.

A report on Wednesday that Akamai Technologies Inc was close to being acquired by Google has no merit, a person familiar with the matter said. Akamai shares were up 4.1 percent to $24.32 and Google edged up 0.15 percent to $549.31.

(Reporting by Ryan Vlastelica; Editing by Kenneth Barry)