The nation's economy unexpectedly shrank by 0.1 percent in the fourth quarter of 2012, casting fresh doubt on the strength of the economic recovery.

The new estimate of gross domestic product (GDP) from the Commerce Department marks the first time the economy shrank since it was in the depths of the recession in mid-2009.

As the "fiscal cliff" loomed, a significant downturn in government and defense spending contributed to the surprising number.

ADVERTISEMENT

Real federal government expenditures and investment fell 15 percent in the fourth quarter, compared to a 9.5 percent increase in the third. And national defense spending tumbled 22.2 percent, compared to a 12.9 percent boost in the third quarter. Non-defense spending actually increased 1.4 percent in the fourth quarter.

The drop in defense spending was the largest in 40 years and, when combined with the slow inventory growth, slashed 2.6 percentage points from the GDP.

The dip came as a surprise to economists. Experts had believed the U.S. would post a modest economic gain of slightly over 1 percent, after logging a 3.1 percent increase in the third quarter.

Mark Zandi, chief economist at Moody's Analytics, said nothing has fundamentally changed in the economy despite the sharp drop in growth. He said several factors “conspired” to produce the negative number.

"The collapse in government spending is a payback from the big defense-spending increase in the third quarter," he said.

Zandi said he is expecting a "significant revision" of the fourth-quarter numbers that will eventually show the economy expanded at a rate of 1.5 percent.

"I will be quite surprised if the year ends with a negative quarter," he said.

The initial estimate for the fourth quarter will be revised twice going forward, but the surprising decline will draw fresh scrutiny to an economic recovery that many thought had finally solidified, positioning the U.S. to make major economic gains in the coming year.

The slowdown in the economy could be a harbinger of things to come in 2013, with a $65 billion cut to federal spending set to begin on March 1 from sequestration unless Congress acts to reverse it. The spending reductions would likely be a drag on the economy in the second and third quarters.

"It's going to hurt," Zandi said of the cuts.

The “fiscal cliff” deal averted sequestration for two months to buy time for negotiations, but hawks in Congress and defense industry officials are beginning to lose hope for an agreement to stop it. One senior defense lobbyist told The Hill this week that the industry has adopted a “mood of acceptance” that sequestration is going to happen.

The austere spending from the public and defense sectors was slightly offset last quarter by a continued surge of spending by consumers and businesses. Personal consumption expenditures were up 2.2 percent in the fourth quarter, compared to 1.6 in the third. And purchases of durable goods also climbed by 13.9 percent, compared to 8.9 percent in the third.

Underlining that boost in personal spending was strong growth in personal income, which was up 7.9 percent, and disposable income, which was up 8.1 percent.

A significant decline in exports (5.7 percent) also contributed to the contraction. Exports had climbed 1.9 percent in the third quarter. State and local government spending was also down in the fourth quarter, 0.7 percent compared to a 0.3 percent gain in the third.

The new report also found that the nation's economy expanded by 2.2 percent in 2012, up from a 1.8 percent gain in 2011.

Vicki Needham contributed.

This story was updated at 10:28 a.m. and 11:35 a.m.