US international trade gap at $43.8B in June vs. $42.8B expected

A container ship docked at the Port of Oakland, in Oakland, Calif.
Getty Images

The U.S. trade deficit widened more than expected in June as an acceleration in domestic demand in the second quarter and a strong dollar sucked in imports of food and automobiles.

The Commerce Department said on Wednesday the trade gap increased 7.1 percent to $43.8 billion, which also reflected a second straight monthly drop in exports.

May's trade gap was revised to $40.9 billion from the previously reported $41.9 billion.

Read MoreUS private sector adds 185,000 jobs in July: ADP

Economists had forecast the trade deficit rising to $42.8 billion. When adjusted for inflation, the deficit increased to $59.3 billion in June from $57.6 billion in the prior month.

The trade data likely will have a marginal impact on the second quarter gross domestic product estimate released last week, as the deficit on the goods balance came in a bit higher than the advance figure incorporated in the GDP report.

In that report, the government estimated the economy expanded at a 2.3 percent annual pace, with trade adding 0.13 percentage point to GDP.

But following stronger-than-forecast construction and factory inventory data, economists expected GDP would be revised to as high as a 3.0 percent annual rate when the government publishes its second GDP estimate later this month.

Domestic demand grew solidly in the second quarter. The dollar, which has gained 15 percent against the currencies of the United States' main trading partners since June 2014, is also making imports cheaper.

In June, imports increased 1.2 percent to $232.4 billion. Despite firming domestic demand, some of the imports likely ended up in inventories, which remained at very high levels in the second quarter.

Read MoreFed's Powell: No decision yet on rate hike in September

Imports of food and automobiles were the highest on record in June. Dollar strength and sluggish global demand crimped exports, which slipped 0.1 percent to $188.6 billion in June.

Exports to the European Union fell 2.3 percent, while imports surged 4.0 percent to a record high. That left the trade deficit with the EU at an all-time high.

Exports to Canada, one of the main U.S. trading partners, slipped 0.1 percent in June. Though exports to Mexico rose solidly, they were outpaced by a jump in imports. That put the trade deficit with Mexico at the highest level since May 2012.

Exports to China increased 10.6 percent, while imports from that country rose 4.9 percent. That left the politically sensitive U.S.-China trade deficit at $31.5 billion, up 3.3 percent from May.