A dip in US sales of autos last month put a dent in the final weeks of the all-important holiday shopping period, which was otherwise robust, government data showed Thursday.

American consumers continued to spend freely, spending more on pricier gasoline while taking home more building supplies, clothing, electronics and sporting goods, according to the Commerce Department.

Total retail sales for December rose 0.3 percent to $529.6 billion, seasonally adjusted, the same increase recorded in the prior two months.

The result matched economists' expectations and put sales up 5.8 percent over December of last year.

Auto sales fell 1.3 percent, however, dragging down the overall result.

Outside the volatile auto sector, US retailers had a better month. Sales surpassed forecasts, rising 0.7 percent.

But much of this was due to a strong 2.8 percent jump in sales at gasoline stations.

Cheverlot Sonic and Bolt EV vehicles outside a General Motors assembly plant Michigan. GM this month reported lower fourth-quarter sales
Cheverlot Sonic and Bolt EV vehicles outside a General Motors assembly plant Michigan. AFP / JEFF KOWALSKY

Elsewhere, there were some signs of sluggishness.

Department stores continued to lose ground to internet retailers like Amazon.

Even so, sales at such "nonstore" retailers rose only 0.2 percent while this year's "Cyber-Monday" sales period fell in December.

Online sales for the final quarter of 2019 fell 0.3 percent compared to the third quarter.

Furniture stores gained a tepid 0.1 percent and gains at bars and restaurants rose only 0.2 percent.

Ian Shepherdson of Pantheon Macroeconomics said December had been a good month overall but GDP calculations for the fourth quarter of 2019 could still suffer.

"The December numbers look good in isolation but they are tempered by downward revisions to prior data," he said in a client note.

This could be followed by a rebound in the first quarter of 2020, he added.