The Commerce Department said on Wednesday the trade gap shrank 7.0 percent to $41.5 billion, the lowest reading since January. That was smaller than the roughly $44.8 billion shortfall the government had assumed in its first snapshot of second-quarter gross domestic product published last week.
"The improvement in June could mean a modest upward revision to the second-quarter GDP estimate," said Millan Mulraine, deputy chief economist at TD Securities in New York. "It also implies a fairly strong hand-off to third-quarter GDP."
The government estimated a week ago that trade subtracted 0.61 percentage point from growth in the April-June period. In that report, it said the economy expanded at a 4.0 percent annual rate during that quarter after shrinking 2.1 percent in the first three months of the year.
Economists had expected a trade gap of $44.7 billion in June, a slight widening from the previously reported $44.4 billion May shortfall. The May gap was revised to $44.7 billion.
Imports fell 1.2 percent in June, the largest drop in a year, to $237.4 billion. That came as petroleum imports declined to $27.4 billion, the lowest level since November 2010, from $28.3 billion in May.
A domestic energy boom has seen the country reduce its dependence of foreign oil. In June, the petroleum deficit fell to its lowest level since May 2009.
Non-petroleum imports were also weak, falling to $167.6 billion from $169.6 billion in May, suggesting a slower pace of inventory accumulation by businesses that month.
They were dragged down by declines in industrial supplies, capital goods, autos and consumer goods. Food imports, however, hit a record high. The decline in imports is at odds with strong manufacturing activity and relatively firm domestic demand.
"With the economy growing, consumer and business spending rising and vehicle sales robust, there is every reason to believe that imports will rebound going forward," said Joel Naroff, chief economist at Naroff Economic Advisors in Holland, Pennsylvania.
Ted Wieseman, an economist at Morgan Stanley in New York, said anecdotal reports pointed to some significant front-loading of imports through the West Coast in July ahead of a feared dock workers strike, which was avoided.
Exports edged up 0.1 percent to a record high of $195.9 billion in June, supported by a surge in automobiles, parts and engines, which rose to an all-time high.
Consumer goods exports also hit a record high. There was also a jump in crude oil exports.
"We still see net exports on pace to contribute to third-quarter GDP," said Wieseman. Third-quarter growth estimates are currently around a 3 percent pace.
Exports to Canada hit an all-time high in June.
Exports to China rose 1.4 percent, while imports from that country increased 3.7 percent.
That left the politically sensitive trade gap with China at $30.1 billion, up 4.5 percent from May.
Editing by Andrea Ricci)