The commission has now sent warning letters to every DHB and pharmacy in the country. It has also warned the Pharmacy Guild, which had advocated for the clauses in the agreement.
Commerce Commission chairman Mark Berry said DHBs had already taken action by removing the restrictive clause from last year's service agreement.
He said removing the clause was an excellent outcome for consumers, who stood to benefit from pharmacies being able to compete on prescription charges.
"Once the no discounting clause was removed, two pharmacies in lower socio-economic areas in Christchurch and Auckland advertised discounting again and noticed an increase in the number of prescriptions being dispensed.
"The outcome of this investigation sends a number of important messages to the parties involved. Government agencies must consider the effects on competition when entering into procurement contracts."
Dr Berry said pharmacies and other health providers must also remember they were in competition with each other, despite the collegial nature of their professions.
He said professional associations, such as the Pharmacy Guild, were also subject to the Commerce Act and needed to pay attention to complying with competition laws.
The Pharmacy Guild said it took its responsibilities seriously and would continue to be mindful of Commerce Act prohibitions against price fixing and anti-competitive agreements.
It would also remind its members of their obligations under the law.
The guild said it acted in good faith during the agreement discussions and provided relevant information to DHBs to enable them to develop a fair service and funding model to support patients.
"Once the unintentional breach was identified in January last year, the DHBs immediately announced that they would not enforce the clauses. The guild fully supported the DHBs' decision and this change was formalised in the revised contract."