When you integrate third-party SDKs into your Mobile Property, you are solely responsible for such integrations. You and the third-party SDK provider must ensure compliant data processing and treatment of any user-based or device-based privacy choices or flags.
You can download and integrate the MAX mediation adapters into your app in two ways:
Do not change the adapter’s name or package name. If you do so, the MAX SDK cannot recognize the adapter and ads will not load.
Choose which mediated ad networks you want to integrate by checking the boxes below. When you check those boxes, this page displays instructions specific to those networks.
This page also creates a customized UPL for you.
Copy the customized UPL below into AppLovinMAX_UPL_Android.xml.
<AARImports>
<insertValue value="com.applovin.mediation,bidmachine-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,bigoads-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,chartboost-adapter,+" /> <insertNewline/>
<insertValue value="com.google.android.gms,play-services-base,16.1.0" /> <insertNewline/>
<insertValue value="com.applovin.mediation,fyber-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,google-ad-manager-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,google-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,hyprmx-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,inmobi-adapter,+" /> <insertNewline/>
<insertValue value="com.squareup.picasso,picasso,2.8" /> <insertNewline/>
<insertValue value="androidx.recyclerview,recyclerview,1.1.0" /> <insertNewline/>
<insertValue value="com.applovin.mediation,ironsource-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,vungle-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,line-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,maio-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,facebook-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,mintegral-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,mobilefuse-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,moloco-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,ogury-presage-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,bytedance-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,pubmatic-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,smaato-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,unityads-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,verve-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,mytarget-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,yandex-adapter,+" /> <insertNewline/>
<insertValue value="com.applovin.mediation,yso-network-adapter,+" /> <insertNewline/>
</AARImports>
<buildGradleAdditions>
<insert>
allprojects {
// You may add any additional repositories for other ad networks here
repositories {
maven { url "https://artifactory.bidmachine.io/bidmachine" }
maven { url "https://cboost.jfrog.io/artifactory/chartboost-ads/" }
maven { url "https://imobile-maio.github.io/maven" }
maven { url "https://dl-maven-android.mintegral.com/repository/mbridge_android_sdk_oversea" }
maven { url "https://maven.ogury.co" }
maven { url "https://artifact.bytedance.com/repository/pangle" }
maven { url "https://repo.pubmatic.com/artifactory/public-repos" }
maven { url "https://s3.amazonaws.com/smaato-sdk-releases/" }
maven { url "https://verve.jfrog.io/artifactory/verve-gradle-release" }
maven { url "https://ysonetwork.s3.eu-west-3.amazonaws.com/sdk/android" }
}
}
</insert>
</buildGradleAdditions>Developers and publishers who use Google AdSense, AdManager, or AdMob must use a consent management platform (CMP) that Google certifies. The CMP must integrate with IAB’s Transparency and Consent Framework when you serve ads to users in the European Economic Area (EEA) or the UK. See Privacy: “TCF v2 consent” for more information.
In the AppLovin MAX Unreal plugin’s AppLovinMAX_UPL_Android.xml, add your Google bidding and Google AdMob App ID under the androidManifestUpdates tag.
In the example below, replace «your-admob-app-id» with your Google bidding and Google AdMob App ID.
<androidManifestUpdates>
⋮
<addElements tag="application">
<meta-data
android:name="com.google.android.gms.ads.APPLICATION_ID"
android:value="«your-admob-app-id»" />
</addElements>
⋮
</androidManifestUpdates>
compileSdkVersionGoogle Mobile Ads SDK versions 23.1.0 and newer require a compileSdkVersion of at least 34.
Set the compileSdkVersion to android-34 or higher in Project Settings > Android SDK > SDK API Level.
Refer to the Google Mobile Ads SDK Release Notes for the latest compileSdkVersion requirements.
Google AdMob requires Android Gradle plugin version 4.2.0 or higher and Gradle version 6.7.1 or higher. If you see the following error, update your Android Gradle plugin and Gradle versions:
AAPT: error: unexpected element <property> found in <manifest><application>.
Some network SDKs include the <queries> element in their bundled Android Manifest files.
If you use an incompatible version of the Android Gradle plugin, this causes one of the following build errors:
com.android.builder.internal.aapt.v2.Aapt2Exception: Android resource linking failed
error: unexpected element <queries> found in <manifest>.
Missing 'package' key attribute on element package at [:com.my.target.mytarget-sdk-5.11.3:]
AndroidManifest Validation failed
To fix this error, upgrade to one of the following versions of the Android Gradle plugin.
These versions support the <queries> element:
Upgrade the Android Gradle Plugin, not the Gradle Build Tools.
| Current Android Gradle plugin version | Version that supports <queries> element |
|---|---|
| 4.1.* | All |
| 4.0.* | 4.0.1+ |
| 3.6.* | 3.6.4+ |
| 3.5.* | 3.5.4+ |
| 3.4.* | 3.4.3+ |
| 3.3.* | 3.3.3+ |
To upgrade the Android Gradle plugin, follow these instructions:
/Users/Shared/Epic Games/UE_5.2/.Engine/Source/Programs/UnrealBuildTool/Platform/Android/UEDeployAndroid.cs, update the value for ANDROID_TOOLS_BUILD_GRADLE_VERSION (replace «X.X.X» with the appropriate version number):
private const string ANDROID_TOOLS_BUILD_GRADLE_VERSION = "com.android.tools.build:gradle:«X.X.X»";
Engine/Build/Android/Java/gradle/build.gradle update the following line (replace «X.X.X» with the appropriate version number):
classpath project.hasProperty('ANDROID_TOOLS_BUILD_GRADLE_VERSION') ? project.property('ANDROID_TOOLS_BUILD_GRADLE_VERSION') : 'com.android.tools.build:gradle:«X.X.X»'
If you do not want to enable Limited Data Use (LDU) mode, pass SetDataProcessingOptions() an empty string array:
⋮
<gameActivityImportAdditions>
⋮
import com.facebook.ads.AdSettings;
</gameActivityImportAdditions>
<gameActivityOnCreateAdditions>
<insert>
AdSettings.setDataProcessingOptions( new String[] {} );
</insert>
</gameActivityOnCreateAdditions>
To enable LDU for users and specify user geography, call SetDataProcessingOptions() in a form like this:
<gameActivityOnCreateAdditions>
<insert>
AdSettings.setDataProcessingOptions( new String[] {"LDU"}, «country», «state» );
</insert>
</gameActivityOnCreateAdditions>
To learn how to implement Meta Audience Network’s “Limited Data Use” flag in California, read the Meta for Developers documentation.
If you use code obfuscation or resource shrinking, follow Pangle’s Obfuscation guidelines.
Unreal Engine requires that you manually integrate third-party frameworks for iOS.
It does not support dependency managers like CocoaPods.
The MAX Unreal GitHub repository includes a Python script — install_pods.py — to assist with automatically installing dependencies from a Podfile.
This script downloads AppLovin adapters and third-party dependencies, and configures your project with build settings to link them.
This script may not be able to automatically configure third-party SDKs for certain networks. If so, you must integrate them manually.
Ensure that you’re using the latest version of CocoaPods. You can check your version by issuing the following command:
pod --version
To update CocoaPods, run one of the following commands:
brew upgrade cocoapods
sudo gem install cocoapodsinstall_pods.py from AppLovin’s MAX Unreal GitHub repository.Source/ThirdParty/IOS/ directory of the AppLovin MAX Unreal plugin.install_pods.py to download the adapters and dependencies.
Follow the instructions from the script to complete installation.Info.plist in AppLovinMAX_UPL_IOS.xml.