Reducing app size

Performance Junior Kotlin 2.0+ API 24+ Reviewed By Best Latest Apps

Order the steps

Order the steps to cut size safely.

  • Move rarely used features to on-demand modules
  • Analyse the release bundle with APK Analyzer
  • Test release builds and compare download size in Play Console
  • Convert PNGs to vectors or WebP
  • Enable R8 minify and resource shrinking, with keep rules where needed

Choose an answer, then open Show answer below to check it.

Show answer

Answer: B E D A C

  1. Analyse the release bundle with APK Analyzer Find the biggest parts first.
  2. Enable R8 minify and resource shrinking, with keep rules where needed Largest win for code.
  3. Convert PNGs to vectors or WebP Shrinks resources.
  4. Move rarely used features to on-demand modules Smaller first download.
  5. Test release builds and compare download size in Play Console Confirm the saving and catch R8 issues.

30-second answer

Ship an Android App Bundle so Play delivers only the code and resources for each device's ABI, density and language. Enable R8 with isMinifyEnabled and isShrinkResources to remove unused code and resources. Use vector drawables and WebP, remove unused libraries, and move rarely used features or large assets to on-demand delivery with Play Feature Delivery or Play Asset Delivery.

Practise saying it · 30 s. No recording, just a timer

Explain how to reduce app size.

Say your answer out loud, then check which of these points you covered:

  • App Bundles
  • R8 minify and shrinkResources
  • Vectors and WebP
  • On-demand delivery
  • Measure with APK Analyzer

Deep dive

The APK Analyzer in Android Studio shows what takes space.

Native libraries are often the biggest part; ship only needed ABIs through the bundle.

Check what each dependency adds before adding it.

Smaller apps have higher install conversion, especially on slow networks.

Common mistakes

  • Shipping a universal APK.
  • Keeping R8 off because 'it might break something'.
  • Bundling large PNGs where vectors would do.

Senior take & follow-ups

Lead with App Bundles and R8, then measure with APK Analyzer.

Follow-up questions

Think of your answer first, then open the hint.

  1. What does R8 do for size?

    Show hint

    Removes unused code, shortens names and, with shrinkResources, drops unused resources.

  2. How do you find the biggest contributors?

    Show hint

    APK Analyzer on the release bundle.

Compare on iOS: Reducing app size App thinning is iOS's version of App Bundle splits.

Suggest a fix if something here is wrong or out of date.