Initialize the Unity Ads SDK in your iOS app. Set your Game ID and use a delegate to manage initialization callbacks and enable ad monetization.
Read time 1 minuteLast updated a day ago
Important
Initialize the SDK early in your project's run-time life cycle before you need to show ads.
Important
You must configure user consent before or during SDK initialization. Serving ads without consent configuration may violate privacy regulations in some regions.
SDK initialization example
Use
UADSInitializationConfigurationBuilder
to construct a configuration object with your Game ID, test mode flag, mediation metadata, and log level, then pass it to
UnityAds.initialize()
. The completion block receives an error object if initialization fails, or