U.S. construction spending unexpectedly posted its biggest increase in eight months in April, advancing for a second straight month as the private sector put money into both residential and nonresidential projects, according to a government report on Monday.

The Commerce Department said spending on construction projects rose 0.8 percent in April from March, the biggest increase since August. Spending climbed a revised 0.4 percent in March, previously reported as a 0.3 percent rise.

Analysts polled by Reuters were expecting a 1.3 percent decline in overall construction spending in April.

Compared to April a year ago, construction spending was down 10.7 percent.

Private construction spending jumped 1.4 percent in April from March, the biggest advance since August. Private residential construction rose 0.7 percent, also the biggest increase since August, after declining 3.6 percent in March.

Spending on public construction fell 0.6 percent in April after increasing 1 percent in March.