The forestry sector also made a strong contribution to export growth for the second consecutive year, driven by record demand for log exports to China. That offset a decline in meat and wool exports.
MPI forecast primary industries exports to rise 9.3% in the year ending June 2018 to $41.6billion.
That anticipated rise was primarily based on dairy prices remaining strong this season, plus a return to normal productivity levels across most sectors following adverse weather last year.
Those trends were projected to continue into the following year, resulting in a forecast of $42.4 billion in the year ending June 2019, up 1.8%.
Compared with the Situation and Outlook report published in June 2017, exports for the year ended June 2017 were $7million higher than previously estimated.
Forecast export revenue for the year ending June 2018 had been revised up by $50 million, reflecting a more positive outlook in meat and wool and seafood, which was offset by a softer outlook for forestry.
That was despite a New Zealand dollar that had strengthened over the past quarter and was now forecast at higher levels over the outlook period.
After reaching $14.6 billion for the year ended June 2017, New Zealand's dairy export revenue was forecast to rise over 18% to $17.3 billion for the year ending June 2018.
Butter prices had continued to rise over the past three months, while whole milk powder prices had stabilised.
Consumer preferences for natural fats, instead of processed vegetable oils, continued to support high butter prices.
Butter prices were expected to continue to rise over the remainder of 2017, before falling slightly from January 2018 onwards.
Growing numbers of bakeries in major Chinese cities were also driving increased demand for butter, with New Zealand's butter exports to China increasing from $355million in 2016 to $443million in 2017.
Dairy export revenue was forecast to remain at $17.3billion for the year ending June 2019 because a small production increase was expected to be offset by a slight fall in dairy prices as butter prices started to recede from current record levels.
Meat and wool export revenue was forecast to expand 1.7% in 2018 after falling 9.2% in the year ended June 2017.
Lower lamb production in New Zealand and Australia were supporting higher lamb export prices. New Zealand's average export prices of beef and veal were expected to be slightly lower in 2018 due to plentiful supply of global exportable supplies.
Lamb production and exports were forecast to lift slightly over the next few years, with exports rising from $2.4billion in 2017 to $2.5billion in 2019.
With high wool inventory levels both in New Zealand and China, and the 2017-18 season's peak production coming in early 2018, it would be difficult for crossbred wool prices to rally in the near term.
Venison exports reached $162 million in the year ended June 2017. Export volumes nearly fell 15% and that lack of supply available to the market helped keep average export prices rising.
Strong prices for both venison and velvet, plus positive population indicators, showed the potential for rebuilding deer herds over the next two years.
Log exports reached $2.7billion for the year ended June 2017 on the back of another record quarter for both prices and harvest volumes.
Log prices remained at historically high levels, surpassing $155 per cubic metre in the June 2017 quarter, and strong global and domestic demand was expected to continue to support strong log prices.
Horticulture export revenue increased 3.2% in the year ended June 2017 despite challenging weather and the November 2016 earthquake damaging wine infrastructure.
Subject to weather, horticultural export revenue was expected to accelerate over the next two years to exceed $5.7 billion by 2019.