Apple has ordered developers not to share data collected from the tech giant's upcoming HealthKit app with advertisers.

The rule was announced as a way to ensure users that they will be able to keep their health information private, according to The Guardian. Developers that build apps using the HealthKit platform will be able to collect data from it.

The Cupertino, California-based company introduced a new app called "Health" in June, designed to collect a variety of information regarding one's health, such as blood pressure, heart rate, exercise and diet.

Developers need permission from the user in order to share data with third parties, and can only do so "for medical research purposes," PC Magazine reported.

All developers who sign up for HealthKit have to agree to these rules, and their app must also come with a privacy policy. Those who don't follow these rules will be banned from the App store and can also face legal penalties.

The rules state that the developer's intent to use the platform for medical reasons must be "clearly evident in your marketing text and user interface," The Guardian reported.

"You and your application may not use the HealthKit APIs, or any information obtained through the HealthKit APIs, for any purpose other than providing health and/or fitness services in connection with your application (eg not for serving advertising)," the rules added.

HealthKit and Health will join other features to be added in Apple's next-gen iOS 8 mobile operating system, such as HomeKit, iMessage updates, Shazam integration, Family Sharing and interactive notifications, according to PC Magazine.

Apple is expected to announce iOS 8's release date at its iPhone event on Sept. 9, where the company is also rumored to introduce two new iPhones and an iWatch.