Stocks advanced on Wednesday after data showed July new home sales rose at their fastest pace in almost a year, while durable goods orders increased, but less than forecast excluding transportation.

Sales of new homes rose for a fourth straight month in July and at their fastest pace since September 2008, while the inventory of unsold homes fell to the lowest level in 16 years, the government reported.

These are great numbers, and they should definitely add fuel to the move higher in the market, said Peter Kenny, managing director at Knight Equity Markets in Jersey City, New Jersey.

It's all very positive, not just because of the macro implications but because they will drive consumer confidence numbers (higher).

The Dow Jones industrial average <.DJI> added 19.57 points, or 0.21 percent, to 9,558.86. The Standard & Poor's 500 Index <.SPX> rose 2.15 points, or 0.21 percent, to 1,030.15. The Nasdaq Composite Index <.IXIC> gained 5.05 points, or 0.25 percent, to 2,029.28.

Homebuilders were among the top gainers, with the Dow Jones home construction index <.DJUSHB> up 3.2 percent. Shares of D.R. Horton Inc jumped 5 percent to $13.70, and Pulte Homes Inc
gained 3 percent to $13.45.

Buoyed by a surge in aircraft orders, durable goods orders jumped 4.9 percent, the largest advance since July 2007, after falling by a revised 1.3 percent in June, the government said.

Earlier, the Mortgage Bankers Association said U.S. mortgage applications rose for a second straight week, with demand for home refinancing loans rising to its highest level since early June.

(Reporting by Rodrigo Campos; additional reporting by Ryan Vlastelica; editing by Jeffrey Benkoe)*