Ground-breaking for new U.S. single-family homes rose for a fifth straight month in July and producer prices tumbled, keeping hopes for an economic recovery alive.

The Commerce Department said on Tuesday construction starts for single-family dwellings, the worst-hit part of the housing market, rose 1.7 percent from June to an annual rate of 490,000 units -- the highest since October.

But a 13.3 percent drop in new multifamily home projects pushed overall housing starts down 1 percent last month to an annual rate of 581,000 units after two months of gains.

The economy is recovering, this is the turning corner. We will have positive growth this quarter, but not a lot of strength. It very much looks like a U-shaped recovery rather than V-shaped, said Kurt Karl, head of economic research at Swiss Re in New York.

Stocks on Wall Street ended higher, also boosted by better-than-expected results from retailers Home Depot Inc and Target Corp, which were largely due to cost cutting and a tight control on inventory.

The Dow Jones industrial average gained 0.9 percent to end at 9,217 while the Standard & Poor's 500 index rose 1 percent to 989. Government bond prices fell, losing some of their safe-haven appeal.

Mohamed El-Erian, chief executive of bond fund manager Pacific Investment Management Co, cautioned the rally in U.S. stock markets had topped out as valuations were running ahead of fundamentals.

While data has pointed to the likely end of the recession that started in December 2007, analysts are wary of a weak recovery as rising unemployment crimps consumer spending.

But there have been some encouraging signs in the labor market, where layoffs are slowing. General Motors said on Tuesday it was increasing production in North America and reinstating 1,350 jobs.

The housing market, the main culprit behind the worst U.S. economic downturn in 70 years, is being closely watched for signs of recovery after a three-year slump.

A survey on Monday showed confidence among home builders rose in August to its highest in over a year.

Home Depot chief financial officer Carol Tome told Reuters in an interview that it was reasonable to believe the U.S. housing contraction was over.

HOUSING RECESSION ENDING

Harm Bandholz, an economist at UniCredit Markets and Investment Banking in New York, agreed the housing recession was drawing to a close. He said weakness in multifamily construction reflected financing problems in the commercial real estate sector and stubbornly high vacancy rates.

Compared to July last year, housing starts were down 37.7 percent, a reminder of how sharply the market had contracted.

Permits for new building, which give a sense of future home construction, fell 1.8 percent in July from a month earlier to stand 39.4 percent below their year-ago level.

However, permits for single-family homebuilding were up 5.8 percent in July, a fourth straight monthly gain and a sign the sector would continue to advance.

The inventory of houses under construction fell to a record low 609,000 last month, while the number of permits authorized but not yet started also hit a record low at 102,300.

While the economy appears to be stabilizing, it is far from full health and some economists think a recovery could falter in 2010, reigniting the risk of a deflation -- an economically disabling, broad-based decline in consumer prices.

A report from the Labor Department on Tuesday showed downward pressure on prices remains, allaying fears that massive programs by the government and the Federal Reserve to stimulate the economy might ignite inflation.

The department said its producer price index, which measures prices received by U.S. farms, factories and refineries, fell 0.9 percent last month after a 1.8 percent gain in June. Compared with the same period last year, the producer price index was down 6.8 percent.

This report is a timely reminder of the remarkable deflationary forces at work in the economy, said Chris Low an economist at FTN Financial in New York.

Core producer prices, which exclude food and energy costs, edged 0.1 percent lower in July after a 0.5 percent increase in June. The core PPI stood 2.6 percent above its year-ago level.

(Additional reporting by Alister Bull in Washington, and Jennifer Ablan and Daniel Burns in New York; Editing by Diane Craft)