Android is expanding per-app memory limits, first introduced in Android 17 on Pixel devices, to a broader range of manufacturers and device RAM configurations (4GB to 16GB+) over the coming year. Apps exceeding their memory budget will be throttled and can be terminated, with the exit reason reported via ApplicationExitInfo as REASON_OTHER and a description containing 'MemoryLimiter:AnonSwap'. Developers are pointed to the Android 17 App Memory Limits documentation, Memory Limiter adb commands for testing, the ProfilingManager API (Android 15+) for heap dumps, and TRIGGER_TYPE_ANOMALY/TRIGGER_TYPE_OOM triggers to monitor and optimize memory footprint ahead of wider enforcement.

2m read timeFrom android-developers.googleblog.com
Post cover image
Table of contents
Understanding Memory LimitsMonitoring and Diagnosing Memory IssuesSummary & What's NextHelpful Resources & References

Questions this post answers

What happens if my Android app exceeds the per-app memory limit introduced in Android 17?

The app will be throttled and may be terminated by the system. The exit reason is reported through ApplicationExitInfo as REASON_OTHER, with a description string containing 'MemoryLimiter:AnonSwap' when the limit caused the termination. Android 17 introduced these per-app memory limits starting with Pixel devices, and more manufacturers are adopting them across 4GB to 16GB+ RAM configurations. daily.dev helps mobile engineers track platform changes like memory throttling before they hit production.

How can I capture a heap dump when my Android app hits a memory limit or OOM condition?

Use the ProfilingManager API introduced in Android 15 (API level 35) to programmatically request and collect Java heap dumps and heap profiles from production devices. Heap dump captures can be triggered automatically based on system signals such as TRIGGER_TYPE_OOM and TRIGGER_TYPE_ANOMALY, the latter useful for catching memory-limit-triggered anomalies. Developers debugging memory issues follow Android tooling updates like this on daily.dev.

How can I test my Android app against different device memory limit configurations?

Android provides Memory Limiter adb commands that let developers simulate different device RAM configurations and per-app memory limits for testing purposes. These commands are documented alongside the Android 17 App Memory Limits behavior changes, enabling developers to validate app behavior before broader manufacturer enforcement rolls out. daily.dev keeps engineers current on adb and platform tooling changes affecting app testing.

9.8K Impressions