Imports exceeded exports by 20 per cent or $774 million last month, pushing the annual trade deficit to $1.7 billion, its widest in nearly four years.
That is $900 million more than the trade deficit for the year to June 2013.
Exports at $3.8 billion were 4.8 per cent lower than in July last year which can only partly be explained by a 3.5 per cent rise in the trade-weighted exchange rate over the past year.
Imports at $4.6 billion were up 17 per cent on a year ago.
Last month's imports were boosted by $152 million worth of helicopters, but even excluding aircraft and parts, imports were 11 per cent higher than in July last year, Statistics New Zealand said.