Google Expands Per-App Memory Limits to More Android Phones
The move is meant to keep devices responsive by compressing excess app memory into zRAM before terminating over-consuming processes, and it requires developers to profile and shrink app memory use.
Overview
- Google announced that per-app memory limits introduced in Android 17 for Pixel will roll out across a wider set of manufacturers and device RAM classes from low-end 4GB phones up to 16GB-plus devices.
- When an app crosses its memory budget the system first forces pages into zRAM, which compresses memory but adds CPU overhead and can cause UI jank, and the OS will terminate the process if usage keeps rising.
- Developers can detect these enforced exits in the field by calling ApplicationExitInfo.getDescription, which returns REASON_OTHER with a description containing "MemoryLimiter:AnonSwap", and they can capture heap dumps with ProfilingManager triggers like TRIGGER_TYPE_ANOMALY and TRIGGER_TYPE_OOM.
- Google is updating tooling and metrics to help teams find and fix problems, including Android vitals memory metrics in Play Console, Memory Limiter adb commands for testing, and Firebase Crashlytics v20.1.0 debug data for OOM and memory-limiter events.
- The change should reduce device-wide slowdowns for users who keep phones longer but will force developers—especially of games and multimedia apps with large heaps—to urgently audit and optimize memory or risk throttling and unexpected process kills.