Sales of recently built single-family homes increased 5.4 percent to a seasonally adjusted 507,000 annual rate, the NAHB said, citing government data.

The Northeast U.S. was strongest with a 23.1 percent increase. Building in the Midwest declined 6.9 percent.

"Today's report is in line with other government data and improving builder sentiment and shows a gradual but consistent housing recovery," said National Association of Home Builders chief economist David Crowe. "As job growth and consumer confidence continue to strengthen, the housing market should make additional gains this year."

There were 218,000 new homes for in July, representing a 5.2 percent supply at existing sales levels, the association said.

"Our builders are reporting higher traffic and more serious buyers, and are adding inventory in anticipation of future business," said NAHB Chairman Tom Woods, a builder from Blue Springs, Mo.