The US trade deficit narrowed in 2023 to the smallest in three years, according to government data released Wednesday, while America bought more goods from Mexico than China for the first time in about two decades.
The latest figures add to a series of positive economic news for President Joe Biden, who has been working to boost sentiment on his handling of the economy as his November reelection campaign picks up pace.
For all of 2023, the overall trade gap was $773.4 billion, down 18.7 percent from the $951.2 billion figure in the prior year, US Commerce Department figures showed.
In 2022, the country saw the biggest deficit in government data dating back to 1960.
But the latest numbers showed a fall in the goods deficit last year, with imports of products dropping more than exports.
Meanwhile, exports of services increased, and the services surplus widened.
Surprisingly resilient consumption last year has helped to support the US economy, but analysts expect the impact of higher interest rates to bite, slowing consumer spending and adding pressure on imports.
In December, the deficit grew slightly from November, added the Commerce Department.
The deficit was $62.2 billion for the final month last year, up $0.3 billion from November's revised $61.9 billion level.
This came as exports and imports both edged up.
"The trade deficit in real terms contributed positively to growth in the quarter," said Matthew Martin, US economist at Oxford Economics.
He added that the December trade figures confirmed what analysts knew from the fourth quarter GDP report.
"The outlook for trade flows going forward is likely one of moderation," said Rubeela Farooqi, chief US economist at High Frequency Economics in a note.
This is due to "expectations of slower demand and growth going forward, both domestically and abroad," she said.
On Wednesday, Commerce Department data also showed that the United States bought more goods from Mexico than China in 2023, a first in around two decades.
This comes as Washington has been pursuing an approach it calls "friendshoring."
This involves diversifying US supply chains across allies and partners amid heightened concern about competition with China and national security tensions between the world's two largest economies.
In 2023, the US goods deficit with Mexico rose to $152.4 billion while that with China decreased to $279.4 billion.
But imports from Mexico jumped by $20.8 billion to $475.6 billion, while the corresponding figure for China fell to $427.2 billion last year.