Starting with iOS 14, you will need to set the
setAdvertiserTrackingEnabled flag. This allows you to inform Facebook whether to use the data to deliver personalized ads in line with your own legal obligations, platform terms, and commitments you’ve made to your users. If the flag is set to
false we will not be able to deliver personalized ads.
You will need to implement the
setAdvertiserTrackingEnabled flag irrespective of the use of mediation.
AdvertiserTrackingEnabledis only available for iOS 14+. For all versions prior to iOS 14, iOS 13 and older, Limit Ad Tracking is used.
setAdvertiserTrackingEnabled method of the
FBAdSettings class and set it to
YES for Objective-C or
true for Swift. On the contrary, set
NO for Objective-C or
false for Swift.
If you are using mediation, then you need to implement the
setAdvertiserTrackingEnabled flag before initializing the mediation SDK in order for us to receive it in the bidding request.
This flag also applies with test mode enabled
// Set the flag as true [FBAdSettings setAdvertiserTrackingEnabled:YES]; // Set the flag as false [FBAdSettings setAdvertiserTrackingEnabled:NO];
// Set the flag as true FBAdSettings.setAdvertiserTrackingEnabled(true) // Set the flag as true FBAdSettings.setAdvertiserTrackingEnabled(false)
// Set the flag as true AudienceNetwork.AdSettings.SetAdvertiserTrackingEnabled(true); // Set the flag as false AudienceNetwork.AdSettings.SetAdvertiserTrackingEnabled(false);
If you do not use the Unity wrapper, use the following:
#if UNITY_IOS AudienceNetwork.AdSettings.SetAdvertiserTrackingEnabled(true); #endif #if UNITY_IOS AudienceNetwork.AdSettings.SetAdvertiserTrackingEnabled(false); #endif