The Commerce Department said on Wednesday that construction spending gained 0.2% after dipping 0.1% in September.

Economists polled by Reuters had forecast construction spending rising 0.4%. Construction spending increased 8.6% on a year-on-year basis in September.

Spending on private construction projects slipped 0.2% in October after falling 0.1% in September. Outlays on residential construction dropped 0.5% after slipping 0.2% in September.

Single-family homebuilding spending declined 0.8% and outlays on multi-family housing projects fell 0.1%. Shortages and more expensive building materials are holding back homebuilding. Residential investment contracted for a second straight quarter in the third quarter, weighed down by decreases in home improvements and single-family homebuilding.

Investment in private non-residential structures like gas and oil well drilling rose 0.2% in October. Spending on structures declined for a second straight quarter in the July-September period, led by commercial and healthcare structures.

Spending on public construction projects shot up 1.8% in October after dipping 0.1% in September. Outlays on state and local government construction projects jumped 0.9%, while federal government spending accelerated 14.6%.

(Reporting by Lucia Mutikani; Editing by Chizu Nomiyama)