U.S. stocks rose modestly on Wednesday after days of selling produced a technical rebound and investors were lured by attractive share prices.
Stocks reversed losses on manufacturing data pointing to a slowing in the U.S. economic recovery.
Energy shares were among the best performers, gaining on higher oil prices.
The S&P 500 index hit its lowest level on an intraday basis since April 19 after closing below its 50-day moving average for a second straight day on Tuesday.
The benchmark index had fallen for three consecutive sessions, dropping 2 percent over that time, with market internals showing declining stocks outnumbering advancers.
It's more of a technical bottom -- the constant selling just got exhausted, said Rick Meckler, president of investment firm LibertyView Capital Management, in New York.
You've had an awful lot of consecutive days of hard selling. It seems like, at least temporarily, that has come to an end.
Bespoke Investment Group said breadth in the S&P 500 was very close to extremely oversold levels, noting the last time those levels were reached on March 16 turned out to be an attractive buying opportunity.
The Dow Jones industrial average <.DJI> gained 36.90 points, or 0.30 percent, to 12,393.11. The Standard & Poor's 500 Index <.SPX> added 4.40 points, or 0.33 percent, to 1,320.68. The Nasdaq Composite Index <.IXIC> rose 13.85 points, or 0.50 percent, to 2,760.01.
Higher oil prices lifted energy companies Chevron Corp
Homebuilders also advanced after luxury builder Toll Brothers Inc
New orders for long-lasting durable goods posted their largest decline in six months in April as aircraft and motor vehicle orders tumbled, a government report showed.
Recent weak U.S. data, including soft manufacturing figures from the Atlantic region and disappointing New York and Philadelphia Fed manufacturing surveys, pointed to a slowdown in the pace of economic growth.
American International Group Inc
(Reporting by Chuck Mikolajczak; Editing by Kenneth Barry)