DEV Community

RatModifier
RatModifier

Posted on

Android App Bundles and Split APKs: Why One APK May Not Be the Whole Application

Android distribution is easy to misunderstand when every downloadable file is casually called 'the APK.' That shorthand works for a traditional standalone package, but it breaks down when an application is published as an Android App Bundle. An App Bundle can be transformed into several APKs that together represent one installed application, with different pieces selected for a device's CPU architecture, language, screen density, or feature set.

For developers, testers, and technical users, the practical consequence is simple: copying a single base.apk from one installation does not necessarily reproduce the complete app on another device. The right troubleshooting question is not only 'Is this APK valid?' but also 'Is this the complete set required for this device?'

1. An AAB Is a Publishing Format, Not an Installable Package

Android App Bundles use the .aab extension. Developers build and sign the bundle, then a distribution system such as Google Play uses the bundle to generate APKs optimized for a particular device configuration. The device ultimately installs APKs, not the AAB itself.

That optimization is the main benefit of the bundle format. A device does not need resources for every supported CPU architecture, language, or screen density. Instead, the distribution system can deliver only the code and resources needed for that configuration.

2. One Installed App Can Be a Set of APKs

A split-based installation normally starts with a base APK containing the core application. Additional configuration APKs can carry device-specific resources such as native libraries for an ABI, language resources, or density-specific assets. Dynamic feature modules can add still more installable components.

Android treats the selected pieces as one application. This is why inspecting only the base package can give an incomplete picture of what the app actually needs at runtime.

3. Missing Required Splits Can Make Sideloading Fail

Google's Android documentation explicitly warns about partial sideloaded installs that are missing required split APKs. On Google-certified devices and devices running Android 10 or later, an incomplete split installation can fail rather than silently installing a broken application.

That behavior is useful. It prevents a user from installing only part of an application and then encountering crashes caused by missing code or resources. If a copied base.apk fails, the answer may be that the original installation was never a one-file application in the first place.

4. bundletool Shows What the Device Actually Needs

bundletool is Google's command-line utility for working with App Bundles. It can generate an APK set, create device-specific APKs, inspect a device specification, and install the correct combination on a connected device.

Generate an APK set from an App Bundle:

bundletool build-apks \
--bundle=/path/app.aab \
--output=/path/app.apks

Capture a connected device specification:

bundletool get-device-spec \
--output=/path/device-spec.json

Generate APKs for a specific device:

bundletool build-apks \
--bundle=/path/app.aab \
--output=/path/device.apks \
--device-spec=/path/device-spec.json

5. Device-Specific Delivery Can Depend on ABI, Density, and Locale

A device specification can include values such as supported ABIs, screen density, Android SDK level, and locales. Those details explain why two phones can receive different APK combinations even though both are installing the same app version.

For example, one device may need an arm64-v8a configuration split while another requires x86_64. The app identity is the same, but the native code delivered to each device is different.

6. Universal APKs Trade Simplicity for Size

bundletool can also build a universal APK. A universal package contains code and resources for all device configurations supported by the included modules, making it easier to share with internal testers.

The tradeoff is size. A universal APK carries resources that a particular device may never use. It is therefore convenient for broad compatibility testing, but it does not have the same delivery efficiency as device-targeted split APKs.

7. An .apks File Is a Container, Not a Single Installable APK

When bundletool creates an APK set, it writes an .apks archive. That file is a container holding APKs for supported configurations. The normal workflow is to let bundletool install-apks choose and deploy the right combination for a connected device.

bundletool install-apks \
--apks=/path/app.apks

Treating the .apks archive as though it were an ordinary .apk file misses the entire point of the format. The archive exists so tooling can select the appropriate package set.

8. Real-World Download Pages Should Be Clear About What They Distribute

A consumer-facing distribution page such as the Gperya Android app download page is a useful example of why wording matters. If a site offers a direct Android file, users should be able to tell whether it is a standalone APK, a package set handled by an installer, or simply a link to another distribution flow.

That link is only a distribution example; it is not evidence about the package format or completeness of any particular download. Those questions must be answered by inspecting the actual artifact and its metadata.

9. A Practical Troubleshooting Matrix

A Developer-Focused Split APK Checklist

  • Identify whether your source artifact is an APK, AAB, or APK set archive.
  • Do not assume base.apk is a complete standalone application.
  • Use bundletool get-device-spec when you need to understand a target device configuration.
  • Generate device-specific APKs when reproducing Play-style delivery locally.
  • Use install-apks to deploy the correct combination from an APK set.
  • Expect universal APKs to be larger because they contain resources for more configurations.
  • When debugging sideload failures, check for missing splits before blaming file corruption.
  • Keep product/download-page claims separate from what the actual package metadata proves.

Conclusion

The Android packaging model has moved beyond the idea that every application is one portable APK file. App Bundles let distribution systems generate device-specific APK combinations, and split APKs let one installed app be assembled from multiple components.

For developers and technical users, that changes the troubleshooting workflow. A failed sideload may be a packaging-set problem rather than a corrupt download. The reliable path is to identify the artifact type, inspect the target device configuration, and use the tooling designed for bundle-based delivery instead of treating every file as a standalone APK.

Technical / Platform References

Android Developers — About Android App Bundles

Android Developers — Build and test your Android App Bundle

Android Developers — bundletool

Android Developers — App Bundle format

DEV Community — Terms / Content Policy

Top comments (0)