Falling prices for dairy and forest product exports drove the trade balance into the red last month.
Imports exceeded exports by $672 million or 19 per cent, reversing the trade surpluses recorded in the previous five July months.
The deficit was bigger than market expectations of $475 million, even though it was flattered by the exclusion of "certain import items for confidentiality reasons".
"We had expected to see the first of Air New Zealand's new Boeing 787 Dreamliners, worth up to $200 million, in the July trade data," ASB economist Nathan Penny said.
On a seasonally adjusted basis, exports of dairy products were down 8.7 per cent from June, reflecting a 4 per cent drop in volumes as well as lower prices.