Some test text!

Search
Hamburger Icon

Android / FAQ / How do I reduce the size of my APK?

Reduce size of APK

Configure APK splits

To reduce size of APK, you can build multiple APKs for specific ABI. For details about multiple APKs, see Build Multiple APKs. The following code snippet in module-level build.gradle file configures multiple APKs based on ABI.

android {
  ...
  splits {

    // Configures multiple APKs based on ABI.
    abi {

      // Enables building multiple APKs per ABI.
      enable true

      // By default all ABIs are included, so use reset() and include to specify that we only
      // want APKs for x86, armeabi-v7a, and mips.

      // Resets the list of ABIs that Gradle should create APKs for to none.
      reset()

      // Specifies a list of ABIs that Gradle should create APKs for.
      include "x86", "armeabi-v7a"

      // Specifies that we do not want to also generate a universal APK that includes all ABIs.
      universalApk false
    }
  }

}

Min version of the Apryse Android SDK

The min version of the SDK optimizes the Apryse libraries for size using the -Os optimization flag (as described here) reducing the AAR sizes.

You can download the Min version of the Apryse Android SDK from our nightly builds.

Get the answers you need: Chat with us