Skip to main content

Android 16 & Target 36 Compatibility Documentation

Android 16 Compatibility

According to Google Play, latest policies for app publishing, starting from August 31, 2025, targetSdkVersion must be API 35 (Android 16) or higher, and from August 2026, it must be API 36 (Android 16) or higher.API 36 (Android 16) is expected to become mandatory in Q3 2026, based on Google's annual enforcement pattern.

To meet long-term compliance requirements and avoid release blocks or app removal risks, Player Network SDK V1.32 has upgraded targetSdkVersion to 36. Integrators need to complete the necessary build environment adjustments.

Behavioral Change Impact

For Android 16, Google has introduced several mandatory behavior changes and permission restrictions. These changes only take effect when targetSdkVersion = 36 and mainly include:

CategoryRemarks
Edge-to-Edge compulsory adaptationView.setSystemUiVisibility and SYSTEM_UI_FLAG_* series constants are completely invalid on Android 16. Use WindowInsetsControllerCompat to implement immersive and full screen.
Predictive Back gestureThe onBackPressed() override method is deprecated and must be replaced by handling the return logic with OnBackPressedDispatcher + OnBackPressedCallback.

For the full list of changes, see Android 16 features and changes.

note

If integrators do not upgrade targetSdkVersion = 36, the above behaviors will not be triggered, and the SDK cannot guarantee correct feature correctness under a non-compatible behavior model.

Support for 16KB Page Size

Starting from Android 16, AOSP supports devices with memory page sizes configured to 16KB.If your app uses any NDK libraries, whether directly or indirectly through an SDK, you will need to rebuild your app to run on these 16KB devices.As device manufacturers continue to produce devices with larger physical memory (RAM), many of these devices will adopt 16KB (or even larger) memory page sizes to optimize performance.Adding support for devices with 16KB memory page size allows your app to run on these devices and benefit from the associated performance improvements.If the app is not recompiled, it may not run properly on devices with 16KB memory pages in future Android versions.

Note: Project adaptation for 16KB memory page size requires engine support. The support status and plans for mainstream engines are as follows:

Currently, only Pixel 8, 8 Pro, and 8a devices running Android 16 QPR1 Beta can enable 16KB mode in Developer Options. The adoption of 16KB mode will take time. Businesses can follow engine support plans to determine or adjust the timing for project support.

Development Environment Compatibility Changes

It is recommended to upgrade Unity to the following LTS version or higher:

  • 2021.3.45f1
  • 2022.3.60f1
  • 6000.0.45f1

Upgrade Android Gradle Plugin (AGP)

Upgrade the Gradle Wrapper version
  1. In the Editor menu, go to Unity > Settings > External Tools, uncheck the Gradle installed with Unity option, and then select the path to the device’s gradle-8.11.1-bin in the Gradle path field below.

  2. Modify the environment variables and set the GRADLE_HOME variable to the path of Gradle version 8.11.1:

    # sh
    export GRADLE_HOME=/Users/***/.gradle/wrapper/dists/gradle-8.11.1-bin/****/gradle-8.11.1
    export PATH=${PATH}:${GRADLE_HOME}/bin
Modify the AGP version dependency
note

After upgrading to Player Network SDK V1.32, AGP has already been upgraded to version 8.9.1 in Assets/Plugins/Android/baseProjectTemplate.gradle, so no further modifications are needed.

Check the "com.android.tools.build:gradle:x.x.x" entry in the Assets/Plugins/Android/baseProjectTemplate.gradle file. If the version is lower than 8.9.1, update it to 8.9.1.Otherwise, no modification is needed.

Upgrade Java version

It is recommended to use the default Java version provided by Unity.

Validation

Basic information confirmation

Unpack the APK, and in the AndroidManifest.xml file inside the package, check the following fields to ensure they meet expectations:

  • Check the package attribute in <manifest> to confirm the package name is correct;

  • Check the platformBuildVersionCode attribute in <manifest>; the expected value should be 36;

  • Check the android:minSdkVersion attribute in <uses-sdk>; the value should match the minimum Android API version supported by your project;

    Android API to Android version reference table: https://apilevels.com/

  • Check the android:targetSdkVersion attribute in <uses-sdk>; the expected value should be 36;

Sample AndroidManifest.xml:

{/* -AndroidManifest */}
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
android:versionCode="1"
android:versionName="1.0"
android:compileSdkVersion="36"
android:compileSdkVersionCodename="14"
package="your.package.name"
platformBuildVersionCode="36"
platformBuildVersionName="14">

<uses-sdk
android:minSdkVersion="16"
android:targetSdkVersion="36" />
......

Compatibility Testing

Use the build for compatibility testing, with a focus on its performance on Android 16.

Appendix