New Zealand has posted a trade surplus, helped by higher kiwifruit exports.
Official figures show a surplus of $127 million in June, compared with a surplus of $348m the month before but a deficit in the same month a year ago.
The country has posted a monthly trade surplus for the past six months, and that's helped to narrow the annual deficit to $3.3 billion.
Exports climbed 2.6 percent on a year ago, while the value of imports fell 4.6 percent.
Statistics New Zealand said the value of kiwifruit was the highest on record in both May and June, boosting annual sales to an all-time high of $1.7 billion.
A senior economist with ANZ Bank, Phil Borkin, said other agricultural products were filling the gap caused by the downturn in the dairy sector.
"We've seen strong growth in fruit," he said, adding that the forestry and seafood sectors had also been performing well.
While there could be a modest deterioration over the next 12 months in the trade balance, it was holding up well, he said.
"Considering the challenges that the dairy sector has faced, it is actually still a pretty decent story."
Imports fell by 4.6 percent to $4.1bn because less was being spent on crude oil, fertiliser, computers and cell phones.
However, analysts did expect the deficit to widen further over time.