App size directly affects install conversion: a user on a mobile network is far more likely to abandon an 80MB app than a 25MB one. Size optimization is both an engineering problem and a growth problem. This guide offers practical techniques to shrink Android and iOS apps, from build configuration to asset handling to dynamic delivery.
First, tell apart the two sizes
- Download size: the compressed size users actually pull over the network — the number that drives install conversion.
- Install size: the size the app occupies on device after extracting.
The optimization target is primarily download size. Stores usually display download size.
Android: start with the App Bundle
The single biggest win comes from switching your publishing format from APK to Android App Bundle (AAB). AAB lets Google Play deliver only the resources (screen density, CPU architecture, language) each device needs, cutting per-device download size by 30%–60% versus a universal APK. It is the largest optimization at near-zero cost.
Code shrinking: R8 / ProGuard
Enable R8 (ProGuard's successor) for code obfuscation and shrinking: it removes unused classes, methods, and fields, and obfuscates names. Pair it with resource shrinking to delete unreferenced resource files. Both reduce size meaningfully but require keep rules to protect reflectively accessed code, and need careful testing.
Asset optimization
- Image formats: replace PNG with
WebPfor big size savings at equal quality; use VectorDrawable for simple bitmaps. - Drop extra ABIs: for direct distribution targeting modern devices only, keep just arm64-v8a and armeabi-v7a, dropping x86/x86_64 (only emulators need them).
- Trim unused dependencies: large libraries often pull in unused transitive deps; review
dependenciesregularly.
Dynamic Feature Modules
For feature-rich apps, split low-frequency features into dynamic feature modules that users download on demand. The base package shrinks, lowering the install barrier; advanced features are fetched when used. This is the "ultimate weapon" for size, but requires engineering work.
iOS: App Thinning and asset handling
The App Store performs App Thinning automatically, generating per-device variants with only the needed slices (architecture, assets), requiring little developer action. What you can still do:
- Manage images via Asset Catalog so the system can slice and load on demand.
- Remove dead code and assets: drop unreferenced old assets and unused frameworks.
- Check duplicate resources: shared assets across targets should live in a common location.
General: size considerations for direct distribution
When distributing a direct APK (bypassing the store), there is no AAB per-device optimization; users download a universal package. Splitting distribution by ABI (separate arm64 and armeabi-v7a packages, routed per device by the distribution platform) can sharply cut per-user download size. A smart distribution platform auto-routes users to the smallest package matching their CPU architecture.
In direct-distribution scenarios, per-ABI packaging plus smart routing is an effective way to cover every device with the smallest download.
Measure and monitor continuously
- Compare download size every release; catch size regressions promptly.
- Use Android Studio's APK/Bundle Analyzer to break down what contributes to size and find the heavyweights.
- Add size to your release checks and alert when it crosses a threshold.
Conclusion
App size is a growth lever you can engineer. On Android, switching to AAB + R8 + resource shrinking is the most effective baseline combo; advanced teams adopt dynamic feature modules. On iOS, lean on App Thinning and Asset Catalog. For direct distribution, use per-ABI packaging and smart routing to compensate for the lack of store optimization. Take size seriously — every megabyte you cut can buy back more installs in the funnel.