Apple App Tracking Transparency

To comply with Apple’s User Privacy and Data Use Policy, all iOS apps running on iOS 14.5 and above must request and obtain explicit user consent before tracking users across apps or websites owned by other companies. This is enforced through Apple’s AppTrackingTransparency (ATT) Framework.

If your app collects data for advertising, analytics, or third-party services, you must present the ATT prompt and respect the user's decision.

Fortunately, Median makes it easy for you to configure your app to utilize Apple's AppTrackingTransparency Framework to remain compliant.

Implementation Guide

Enable ATT in Your App Configuration

  • Open the Permissions tab in the App Studio.
  • Enable App Tracking Transparency.
  • Choose how the ATT prompt is displayed:
    • Automatic - The prompt is shown automatically on the first app launch.
    • Manual - You control when the prompt appears via JavaScript.

You may provide your own description to explain why tracking is used, or use the default text supplied by Median.

ATT App Configuration

ATT App Configuration

Prompt for User Consent at Runtime (Manual Method)

If you prefer to trigger the ATT prompt at a specific moment in your app (e.g., after onboarding or before accessing personalized content), use the following JavaScript function:

↔️Median JavaScript Bridge

function request() {
  median.ios.attconsent.request()
    .then(function (result) {
      // Handle user's response
      if (result.granted) {
        // Proceed with tracking logic
      } else {
        // Disable tracking
      }
    });
}

The result object will be { granted: true|false } based on the user's response to the consent prompt. For iOS 14.4 and lower, result object will always be { granted: true}

Check ATT Consent Status

You can check whether the user has already responded to the ATT prompt using the following function:

↔️Median JavaScript Bridge

function status() {
  median.ios.attconsent.status()
    .then(function (result) {
      // Use result.granted to determine tracking logic
    });
}

The result object will be { granted: true|false } based on the user's response to the consent prompt. For iOS 14.4 and lower, result object will always be { granted: true}

This is useful for conditional logic. For example, adjusting third-party SDK behavior or disabling analytics for non-consenting users.

Additional Resources