The Health Ministry has made a $45 million-a-year data deal to help protect hospitals from cyber attacks.
At the same time, it has launched a strategy to improve the way health data is collected, managed and shared.
District health boards have been struggling for years to update their beleaguered IT systems, culminating in the ransomware attack on Waikato in May.
The ministry said the three-year deal with Microsoft delivered $27m in savings.
It should lead to increased deployment of cyber security technology across health agencies "which will improve protection and resilience to cyberattacks".
The deal draws the ministry, the incoming national health agencies and DHBs under a single national contract for the first time.
"Technology is a key enabler for the reforms and these arrangements give Health New Zealand and the Māori Health Authority the tools they need right from the start," the ministry said.
Integration is also the goal of the health data strategy and two-year action plan.
It comes as IT health experts grow increasingly frustrated with a fractured system where some hospitals still rely on faxes, and cannot share patient records easily.
The plan sets out the work "that needs to be done over the next couple of years so New Zealanders are clear about what happens to the information they share with health and other providers", deputy director-general data and digital Shayne Hunter said in a statement.
The plan's five priorities include getting tech that integrates this, making ways for people to authorise others such as whānau to access their health information, and setting up firmer controls through governance that covers local people and Māori.