Sales of previously owned homes hit a three-month low in June while new claims for jobless benefits surged last week, the latest indications that the economy is on the ropes.

Another report on Thursday showed a gauge of the economy's prospects fell last month, consistent with views the recovery was cooling and that the slowdown could persist through the end of the year.

The housing data was not as bleak as financial markets had feared, however, and some analysts and investors took heart that home prices rose. U.S. stocks added to gains and all three major indexes were up more than 2 percent in mid-morning trade, while prices for safe-haven government bonds fell.

Existing home sales fell 5.1 percent to an annual rate of 5.37 million units, the National Association of Realtors said. Financial markets had expected sales to fall 8.1 percent. The median home sales price in June was $183,700, a 1.0 percent increase from the prior year.

It's still a horrible number. It's just not as horrible as what people were looking for. Do you really view that as good news? Apparently the stock market does, said Mary Ann Hurley, vice president of fixed-income trading at D.A. Davidson & Co in Seattle.

A separate report from the Labor Department showed initial claims for state unemployment benefits rose 37,000 to a seasonally adjusted 464,000 last week, more than erasing a decline in the prior week.

Financial markets had forecast claims rising to 445,000. The claims report covered the survey week for government's closely monitored employment report for July, which is scheduled for release on August 6.

UNUSUALLY UNCERTAIN OUTLOOK

In congressional testimony on Wednesday and Thursday, Federal Reserve Chairman Ben Bernanke described the outlook as unusually uncertain and said the U.S. central bank stood ready to take further steps to aid the economy if needed.

We are ready and we will act if the economy does not continue to improve if we do not see the kind of improvements in the labor market that we are hoping for and expecting, he told the House of Representatives Financial Services Committee on Thursday.

The Conference Board's index of leading economic indicators slipped 0.2 percent in June after rising 0.5 percent in May.

The indicators point to slower growth through the fall. Improvement in the industrial core of the economy will moderate as inventory rebuilding slows, said Ken Goldstein, an economist at the Conference Board.

Improvement in the services sector has been relatively slow, with little indication that it will pick up momentum.

Job growth has slowed after strong gains early in the year, crimping household spending and holding back the economy's recovery from the most painful recession since the 1930s.

In the week ended July 10, the number of people still receiving benefits after an initial week of aid dropped 223,000 to 4.49 million, the Labor Department said, well below market expectations for 4.62 million.

That resulted in the insured unemployment rate, which measures the percentage of the insured labor force that is jobless, falling to 3.5 percent during that period from 3.7 percent in the prior week.

The number of people on emergency benefits declined 404,049 to 3.48 million in the week ended July 3, but the figure is set to rise in coming weeks after the Senate finally voted late on Wednesday to extend benefits for the long-term unemployed.

Some 2.5 million unemployed Americans have seen their benefits lapse since the end of May as the Senate was deadlocked over how to cover the $34 billion cost of extending them through November.

According to Labor Department data, about 45 percent of the 14.6 million people unemployed in June had been out of work for six months or more.

(Reporting by Lucia Mutikani; Additional reporting by Corbett Daly; Editing by James Dalgleish)