The deficit in U.S. trade of goods and services narrowed in June for the first time since February as demand and logistics began to stabilize.

Exports increased from the prior month by 9.4 per cent, the most in records back to 1992 to US$158.3 billion, according to Commerce Department data released Wednesday. Imports climbed 4.7 per cent, the most since March 2015, to US$208.9 billion.

Both increases reflected a pick-up in shipments of autos and parts after factories restarted production.

The overall gap in goods and services trade narrowed to US$50.7 billion, compared to the median estimate of US$50.2 billion by a Bloomberg survey of economists, from a revised US$54.8 billion in May.

The coronavirus pandemic has wreaked havoc on trade globally and in the U.S., the world’s largest economy has pulled back sharply since the outbreak began amid a surge in unemployment and a slowdown in international travel. At the same time, American exporters may stand to benefit from a recent decline in the value of the dollar, which makes U.S. goods more competitive in overseas markets.