Stocks snapped a four-day losing streak on Monday, after a broker issued a bullish call on big banks and as data showed the services sector expanded for the first time since August 2008.

Financial stocks rallied after Goldman Sachs upgraded the large-cap bank sector to attractive from neutral, saying that share prices for companies in the industry didn't reflect their earnings power.

Goldman also upgraded Wells Fargo & Co to buy, and its shares rose 5.8 percent to $27.80. The KBW Banks index <.BKX> advanced 2.4 percent while the S&P Financial index <.GSPF> added 2.4 percent and was the top percentage gainer among S&P sectors.

The Institute for Supply Management's index for the U.S. services sector rose to 50.9 in September, crossing the 50 threshold that indicates expansion and topping expectations. The services sector represents about 80 percent of the U.S. economy.

We were set up for a positive start, given the two rough weeks we've had, said Linda Duessel, market strategist at Federated Investors in Pittsburgh. We were oversold, and then the ISM surprised to the upside, adding to positive sentiment.

The Dow Jones industrial average <.DJI> gained 82.53 points, or 0.87 percent, to 9,570.20. The Standard & Poor's 500 Index <.SPX> rose 11.59 points, or 1.13 percent, to 1,036.80. The Nasdaq Composite Index <.IXIC> added 16.60 points, or 0.81 percent, to 2,064.80.

The move to the upside came after markets posted their second straight week of losses last week, as investors questioned the strength and timing of an economic recovery after weak data on jobs and factory orders.

The fact that we're seeing this kind of follow-through after recent losses gives me the distinct impression that the market is feeling pretty confident going into earnings season, said Craig Peckham, equity trading strategist at Jefferies & Co in New York.

Shares of Brocade Communications Systems Inc surged 15.8 percent to $8.86 after The Wall Street Journal reported that the network equipment maker had put itself up for sale, citing sources familiar with the matter.

Also on the acquisition front, Dutch telecoms group KPN NV raised its buyout offer to minority shareholders of iBasis Inc to $2.25 a share from $1.55 a share. Shares of iBasis, a U.S. voice traffic carrier, surged 7.5 percent to $2.30.

Dow component Caterpillar Inc added 3 percent to $50.28 after Morgan Stanley raised its price target on the stock by $10 to $44, and after the company said it planned to raise prices on most of its machinery next year.

(Editing by Leslie Adler)