Stocks fell on Wednesday after Goldman Sachs posted a decline in quarterly profit, denting investor optimism.

Goldman Sachs Group Inc fell 2.6 percent to $170.07 after it posted a 53 percent decline in profit as trading revenue tumbled, spoiling hopes that Wall Street's most influential bank might buck a volatile climate that has hurt rivals such as Citigroup Inc .

Shares of Wells Fargo & Co fell 1.4 percent to $32.03 after the company posted a fourth-quarter profit that missed some analysts' estimates.

Shares of American Express Co fell 1.8 percent to $45.49 after the company said restructuring charges, related to closing down some locations in its global servicing network, would reduce fourth-quarter earnings.

Banks had some difficulty with revenue as seen with Goldman Sachs this morning, said Robert Pavlik, chief market strategist at Banyan Partners LLC in New York.

Despite concerns over bank results, earnings from Apple Inc and International Business Machines Corp came in stronger than forecast.

Apple's profit blew past Wall Street expectations on strong sales of iPhones, iPads and Mac computers. The stock was up 2 percent at $347.44 as a number of brokerages including Goldman Sachs and Bank of America Merrill, raised their price targets on the stock.

Shares of IBM rose 2.2 percent to $153.90.

The Dow Jones industrial average <.DJI> was up 7.50 points, or 0.06 percent, at 11,845.43. The Standard & Poor's 500 Index <.SPX> was down 4.30 points, or 0.33 percent, at 1,290.72. The Nasdaq Composite Index <.IXIC> was down 10.24 points, or 0.37 percent, at 2,755.61.

(Editing by Padraic Cassidy)