Second Quarter GDP Unexpectantly Accelerates.

David Paul Morris | Bloomberg | Getty Images

A container ship leaves the San Francisco Bay in San Francisco, California, U.S.

U.S. economic growth unexpectedly accelerated in the second quarter, laying a firmer foundation for the rest of the year that could bring the Federal Reserve a step closer to cutting back its monetary stimulus.

Economists polled by Reuters had forecast the economy growing at a 1.0 percent pace after a previously reported 1.8 percent advance in the first three months of the year.

A rebound in business spending, export growth and a sharp moderation in the pace of decline in government outlays boosted economic growth in the April-June period, offsetting a slowdown in consumer spending and a steady rate of inventory accumulation.

Still, the report marked a third straight quarter of GDP growth below 2 percent, a pace that normally would be too soft to bring down unemployment. But growth was poised to gain even more momentum in the second half of the year as the fiscal burden brought on by belt-tightening in Washington eases.

Federal Reserve officials, wrestling with a decision on the future of their $85 billion per month bond-buying program, will probably nod to the downward revision to first-quarter growth, but draw comfort from the pick-up in output last quarter, when they wind-up a two-day meeting later on Wednesday.

Fed Chairman Ben Bernanke said last month that the central bank was likely to start curtailing the bond purchases later this year and would probably bring them to a complete halt by the middle of 2014, if the economy progressed as expected.

Silver lining in revisions

Play Video

Q2 GDP (advance) up 1.7%

CNBC’s Rick Santelli breaks down the unexpected growth in second quarter GDP numbers and discusses what it indicates about the economy and its impact on the markets, with CNBC’s Steve Liesman, and Bruce Kasman, JPMorgan.

Adding to the better tenor of the report, comprehensive revisions to the data cast the economy in a better light than previously.

The government has implemented some changes in how it calculates GDP. For example, research and development spending will now be treated as investment, and defined benefit pension plans will be measured on an accrual basis, rather than as cash.

Economic growth was relatively stronger between 2009 and 2012 than previously reported. In fact, the economy grew 2.8 percent last year, 0.6 percentage points faster than the government had previously estimated.

The revisions also yielded a higher rate of savings, a good omen for consumer spending in the future.

Higher taxes, as Washington tries to shrink the government’s budget deficit, constrained consumer spending in the second quarter, keeping the economy on an anemic growth pace.

Consumer spending, which accounts for more than two-thirds of U.S. economic activity, slowed to a 1.8 percent growth pace after rising at a 2.3 percent rate in the first quarter.

With domestic demand tepid, businesses kept their inventories from bulging. Inventory accumulation added 0.41 percentage point, less than half the contribution from the prior quarter.

Other details of the report showed exports rebounded, showing the largest percentage gain since the third quarter of 2011, even as demand weakened in Europe and China. But the increase was not enough to offset a rise in imports, leaving a trade deficit that weighed on growth.

There was good news from the housing sector, with double-digit growth for spending on residential construction. Housing, which triggered the 2007-09 recession, is growing strongly, helping to keep the economic recovery anchored.

Business spending on equipment and software reversed the prior quarter’s decline, lifted by a turnaround in investment in nonresidential structures and gains in outlays on equipment and intellectual products.

While government spending contracted for a third straight quarter, the pace of the decline slowed sharply as state and local government spending rebounded. Defense spending fell marginally after declining sharply in the past two quarters.