WASHINGTON (MarketWatch) -- U.S. sales of new homes scored a better-than-expected rebound in June after having plumbed record lows a month earlier, government data showed Monday.

Sales rose 23.6% in June to a seasonally adjusted annual rate of 330,000, the Commerce Department reported.

Economists said the gain wasn't a sign of strength but was welcome nonetheless, coming after a reading for May that turned out more dismal than first projected.

New-home sales for May plummeted a revised 36.7% to a record low 267,000 level after a federal subsidy for home buyers expired. This is a steeper drop than the 32.7% fall and 300,000 in annualized sales that the government initially estimated.

"Builders sold almost no new homes in May so the sharp rise in June shouldn't be taken as a sign the housing market is suddenly on fire," wrote Joel Naroff, president of Naroff Economics Advisers.

All the same, stocks got an immediate lift from the data and Wall Street remained broadly higher at midday. See Market Snapshot for the current market activity.

Despite the big bounce, this is still the second lowest sales rate on record.

Economists had been expecting a slight bounce back to a 316,000 rate for June. See MarketWatch calendar of all major indicators.

Shares of home builders rallied, easily outpacing gains in the broader U.S. equity benchmarks.

Hovnanian Enterprises Inc. HOV, +5.41% , Beazer Homes USA Inc BZH, +1.07% , and Pulte Group Inc. PHM, +2.25% all gained more than 5% in afternoon trading.

By region, last month's sales rose in all regions except the West, where sales hit a new record low. Compared with June 2009, last month's sales were down 16.7%.

In June, the number of unsold new homes on the market slipped 1.4% to 210,000, the fewest since September 1968. That represented a 7.6-month supply at the June sales pace, less than the 9.6-month supply in May.

The median sales price of $213,400 in June was down 0.6% compared with a year earlier. Read full government release.

Where from here?

Economists said the weakness in the housing sector has been laid bare since government support for the sector, which lasted for more than two years, ended.

The government had been providing up to $8,000 to qualified buyers. But the sales contract had to be signed by the end of April to receive the credit. In addition, the sale must close by Sept. 30.

The big question is whether the housing sector can strengthen from here.

Despite the rebound in sales of newly built homes, most other recent housing data have pointed to further weakness. Mortgage applications are trending lower in July and a measure of home builder confidence also fell.

Moreover, sales of existing homes fell 5.1% in June to a 5.37 million rate, according to the National Association of Realtors. See full story.

The government cautions that its housing data are subject to large sampling and other statistical errors. Large revisions are common.

The standard error this month was 15.3%.

It can take up to six months for a trend in sales to emerge. New-home sales have averaged 354,000 per month over the past six months, roughly unchanged from the same period ended in May.

The inventory of completed-but-unsold homes fell to 81,000, down about 37% in the past year and the lowest level since October 2003.