WASHINGTON (MarketWatch) — The U.S. economy sprang back to life in second quarter and expanded at the fastest pace since last fall, fueled by a upturn in consumer spending on big-ticket items such as cars and trucks as well as a sharp rebound in business investment.

Gross domestic product — the value of all goods and services produced by the U.S. — grew at a 4% annual clip in the second quarter, the government said Wednesday. Newly revised figures also show the economy contracted by a somewhat smaller 2.1% in the first quarter instead of 2.9%.

Economists polled by MarketWatch predicted GDP would grow by a seasonally adjusted 3.2% in the April-to-June period. In recent trades, U.S. stocks SPX, -1.11% started higher before turning lower in late morning trade. Read Market Snapshot.

Also read:How much did subprime fuel the GDP boom?

The rebound in growth offers further proof that a plunge in first-quarter GDP was an outlier. The economy contracted sharply in the first three months of the year mainly because of an unusually harsh winter and a decline in health-care spending tied to the introduction of Obamacare.

The second-quarter rebound “provides evidence that the economy is healthy and will continue to grow at an above-average rate in the second half of this year and into 2015,” asserted Douglas Handler, chief U.S. economist at IHS Global Insight.

Economists polled by MarketWatch predict the U.S. will expand by 3%-plus in the third and fourth quarters. They base their optimism on a surge in hiring that’s added 1.39 million new jobs in the first half of 2014, marking the best six-month stretch since the Great Recession ended in mid-2009.

More hiring usually leads to more consumer spending and spurs businesses to further increase hiring and investment.

Consumers go big ticket

Consumer spending, the main wellspring of economic activity, accelerated in the spring to show a solid 2.5% gain after a meager 1.2% advance in the first quarter. Health-care spending rose modestly, reversing a decline early in the year that contributed to the big drop in U.S. growth.

Fatter stock dividends also helped to boost inflation-adjusted disposable income by 3.8% in the second quarter and underpin the increase in spending.

Consumers mostly shelled out for major items such as cars and trucks. Spending on goods designed to last three years or more shot up 14%, the largest gain since 2009.

Outlays on services such as financial advice and personal care rose a slim 0.7%, however. Part of the weakness stemmed from lower utility payments as the weather warmed — a good thing — but spending on services typically rises a lot faster when the economy is firing on all cylinders.

Also adding to growth was a pickup in construction spending, increased business investment, a bigger buildup in inventories and slightly higher government spending.

Investment in residential housing rose 7.5% and business spending on equipment climbed 7%. Spending in both of those areas fell in the first three months of the year.

The increase in inventories climbed to $93.4 billion — up from just $35.2 billion in the first quarter — and accounted for 40% of the increase in GDP. What’s unclear is whether businesses restocked warehouse shelves in anticipation of rising sales or to catch up after a tough winter. Slower restocking in the third quarter could reduce U.S. growth, though most economists don’t expect a big dropoff.

The federal government, for its part, slightly reduced spending. Yet a 3.1% pickup at the state and local level boosted overall government outlays.

The only major drag on second-quarter growth was net exports. Imports rose a faster 11.7% compared to a 9.5% advance in exports.

Inflation as measured by the Federal Reserve’s preferred price index, meanwhile, surged in the second quarter to the highest annual rate in three years, potentially making the central’s bank effort at managing the U.S. recovery more difficult.

The PCE index rose at a 2.3% annual rate in the April-to-June period, compared to 1.4% in the first quarter. That’s the fastest pace since the second quarter of 2011. The core PCE that excludes food and energy, the Fed’s preferred inflation gauge, climbed at a 2% clip, up from 1.2%.

The Fed believes the pickup in inflation has been exaggerated by temporary factors that should ease soon, but if the central bank is wrong, it could be forced to raise interest rates sooner than it would like.

The Fed would like to see inflation in an annual range of 2% to 2.5% — anything much higher or lower is viewed by most top bank officials as harmful to the economy in the long run.

Top Fed officials met Wednesday to plot their next move. The central bank is winding down a massive stimulus program on the expectation that growth will continue to improve.

GDP is revised twice after its initial release. The second estimate will come out next month, and sometimes the revisions are quite large. The drop in first-quarter GDP, for instance, was initially reported as 0.1% before eventually being lowered to show a much larger decline.

Earlier, ADP reported that private-sector payrolls grew by 218,000 in July.