{
	"id": "f5a5a7af-9a85-4726-ae07-d437e1b7246f",
	"created_at": "2026-04-06T00:13:00.752297Z",
	"updated_at": "2026-04-10T13:12:54.980338Z",
	"deleted_at": null,
	"sha1_hash": "24fc1d2192dea5d4f9120a4d923364a98286b0ee",
	"title": "App hibernation",
	"llm_title": "",
	"authors": "",
	"file_creation_date": "0001-01-01T00:00:00Z",
	"file_modification_date": "0001-01-01T00:00:00Z",
	"file_size": 86137,
	"plain_text": "App hibernation\r\nArchived: 2026-04-02 11:55:24 UTC\r\nIf your app targets Android 11 (API level 30) or higher, and the user doesn't interact with your app for a few\r\nmonths, the system places your app in a hibernation state. The system optimizes for storage space instead of\r\nperformance, and the system protects user data. This system behavior is similar to what occurs when the user\r\nmanually force-stops your app from system settings.\r\nEffects of hibernation\r\nAs shown in table 1, the effects of hibernation depend on your app's target SDK version, as well as the device on\r\nwhich your app is running:\r\nTable 1. Effects of hibernation on your app\r\nTarget SDK\r\nversion\r\nCharacteristics of device Hibernation effects\r\nAndroid 12\r\nor higher\r\nRuns Android 12 or higher\r\nYour app's runtime permissions are reset. This\r\naction has the same effect as if the user viewed a\r\npermission in system settings and changed your\r\napp's access level to Deny.\r\nYour app can't run jobs or alerts from the\r\nbackground.\r\nYour app can't receive push notifications,\r\nincluding high-priority messages that are sent\r\nthrough Firebase Cloud Messaging.\r\nAny files in your app's cache are removed.\r\nAndroid 11 Runs Android 11 Your app's runtime permissions are reset.\r\nAndroid 11\r\nRuns Android 6.0 (API level 23) to\r\nAndroid 10 (API level 29), inclusive,\r\nand is powered by Google Play\r\nservices\r\nYour app's runtime permissions are reset.\r\nThis behavior takes effect in December 2021.\r\nLearn more in this blog post about making\r\npermissions auto-reset available to billions more\r\ndevices.\r\nhttps://developer.android.com/topic/performance/app-hibernation\r\nPage 1 of 6\n\nSystem behavior when an app leaves hibernation\r\nWhen the user next interacts with your app, your app exits hibernation, and it can create jobs, alerts, and\r\nnotifications again.\r\nHowever, the system doesn't do the following for your app:\r\n1. Re-grant your app's runtime permissions.\r\nThe user must re-grant these permissions for your app.\r\n2. Reschedule any jobs, alerts, and notifications that were scheduled before your app went into hibernation.\r\nTo support this workflow more easily, use WorkManager. You can also add rescheduling logic in the\r\nACTION_BOOT_COMPLETED broadcast receiver, which is invoked when your app leaves hibernation and after\r\nthe device boots up.\r\nApp usage\r\nThe following sections provide examples of app usage, as well as examples of actions that the system doesn't\r\nconsider to be app usage.\r\nExamples of app usage\r\nWhen an activity in your app is resumed, the system considers this event to be a user interaction. Therefore, the\r\nsystem extends the amount of time before your app enters hibernation.\r\nOn Android 11 and higher, the following behaviors are also considered to be user interactions:\r\nThe user interacts with a widget.\r\nThe user interacts with a notification, except for dismissing the notification.\r\nIt should be noted that app usage for hibernation doesn't explicitly require user interaction. As long as a\r\ncomponent of the package is invoked, it is still considered app usage. Some examples of this include:\r\nApps that have a service or content provider bound by another app on the device or the OS. For example,\r\nInput Method Editors (IMEs) or password managers.\r\nBroadcast receivers in the package receiving an explicit broadcast from an external package.\r\nNon-examples\r\nIf your app only ever exhibits the behaviors described in the following list, your app enters hibernation after a few\r\nmonths:\r\nRuns a scheduled job using JobScheduler .\r\nReceives an implicit broadcast.\r\nhttps://developer.android.com/topic/performance/app-hibernation\r\nPage 2 of 6\n\nSchedules alarms.\r\nSystem exemptions from hibernation\r\nAndroid grants system-level exemptions from app hibernation in certain use cases. If your app falls into one of the\r\nfollowing categories, it is exempt from the app usage standards and will not hibernate.\r\nApps not displayed on the launcher\r\nAny app that doesn't have an active shortcut tile on the launcher.\r\nWork profile apps\r\nAny app that a user installs on a work profile. Note that if the same app also resides on a personal profile,\r\nonly the work profile app is exempt.\r\nDevice policy controllers\r\nApps that control local device policies and system applications on devices.\r\nCarrier privileged apps\r\nAny app that mobile phone carriers pre-load on devices and deem necessary for contractual service\r\nobligations, for example, voicemail or customer service apps.\r\n3p installer apps\r\nThird-party app stores for automatic updates of their installed apps when necessary.\r\nUser exemptions from hibernation\r\nIf you anticipate that a core use case in your app is affected by hibernation, you can request an exemption from\r\napp hibernation from the user. This exemption is useful for situations in which the user expects your app to work\r\nprimarily in the background, even without the user interacting with your app, such as when your app does any of\r\nthe following:\r\nProvide family safety by periodically reporting the location of family members.\r\nSync data between a device and your app's server.\r\nCommunicate with smart devices, such as a TV.\r\nPair to companion devices, such as a watch.\r\nTo request an exemption, complete the steps in the following sections.\r\nCheck whether the user has already disabled hibernation for your app\r\nTo check whether the user has already disabled hibernation for your app, use the\r\ngetUnusedAppRestrictionsStatus() API.\r\nFor additional details on how to use this API in your app, see the API code example on this page.\r\nAsk the user to disable hibernation for your app\r\nIf the user hasn't already disabled hibernation for your app, you can send a request to the user. To do so, complete\r\nthese steps:\r\nhttps://developer.android.com/topic/performance/app-hibernation\r\nPage 3 of 6\n\n1. Display a UI that explains to the user why they need to disable hibernation for your app.\r\n2. Invoke the createManageUnusedAppRestrictionsIntent() API, as shown in the API code example. This\r\nAPI creates an intent that loads the App info screen in Settings. From here, the user can turn off\r\nhibernation for your app.\r\nIt is important that you call startActivityForResult() , not startActivity() , when sending this intent.\r\nAs shown in table 2, the option's location and name depends on the characteristics of the device on which\r\nyour app is installed:\r\nTable 2. Option that disables hibernation for your app\r\nCharacteristics of device\r\nPage where the option\r\nappears\r\nName of the option\r\nto turn off\r\nRuns Android 13 or higher App info\r\nPause app activity if\r\nunused\r\nRuns Android 12 App info\r\nRemove permissions\r\nand free up space\r\nRuns Android 11 App info \u003e Permissions\r\nRemove permissions\r\nif app isn't used\r\nRuns Android 6.0 to Android 10,\r\ninclusive, and is powered by Google\r\nPlay services\r\nPlay app \u003e Menu \u003e Play\r\nProtect \u003e Permissions for\r\nUnused Apps\r\nRemove permissions\r\nif app isn't used\r\nAPI code example\r\nThis code example shows how to check whether hibernation is enabled for your app, and the correct way to ask\r\nusers to disable hibernation for your app.\r\nval future: ListenableFuture\u003cInt\u003e =\r\n PackageManagerCompat.getUnusedAppRestrictionsStatus(context)\r\nfuture.addListener({ onResult(future.get()) }, ContextCompat.getMainExecutor(context))\r\nfun onResult(appRestrictionsStatus: Int) {\r\n when (appRestrictionsStatus) {\r\n // Couldn't fetch status. Check logs for details.\r\n ERROR -\u003e { }\r\n // Restrictions don't apply to your app on this device.\r\n FEATURE_NOT_AVAILABLE -\u003e { }\r\n // The user has disabled restrictions for your app.\r\n DISABLED -\u003e { }\r\nhttps://developer.android.com/topic/performance/app-hibernation\r\nPage 4 of 6\n\n// If the user doesn't start your app for a few months, the system will\r\n // place restrictions on it. See the API_* constants for details.\r\n API_30_BACKPORT, API_30, API_31 -\u003e handleRestrictions(appRestrictionsStatus)\r\n }\r\n}\r\nfun handleRestrictions(appRestrictionsStatus: Int) {\r\n // If your app works primarily in the background, you can ask the user\r\n // to disable these restrictions. Check if you have already asked the\r\n // user to disable these restrictions. If not, you can show a message to\r\n // the user explaining why permission auto-reset or app hibernation should be\r\n // disabled. Then, redirect the user to the page in system settings where they\r\n // can disable the feature.\r\n val intent = IntentCompat.createManageUnusedAppRestrictionsIntent(context, packageName)\r\n // You must use startActivityForResult(), not startActivity(), even if\r\n // you don't use the result code returned in onActivityResult().\r\n startActivityForResult(intent, REQUEST_CODE)\r\n}\r\nLegacy platform API\r\nThe operating system also includes an API to interact with the hibernation feature. However, the API only works\r\non devices that run Android 11 or higher; the API doesn't handle the hibernation features that are backported to\r\nearlier Android versions. Therefore, we don't recommend using the API.\r\nIf you need to continue using the API temporarily for compatibility purposes, the following list shows how to use\r\nit:\r\nTo check if hibernation is disabled for your app: isAutoRevokeWhitelisted()\r\nTo send the user to the hibernation settings page: create an Intent using\r\nACTION_APPLICATION_DETAILS_SETTINGS\r\nManually invoke hibernation behavior\r\nTo test how your app behaves after the system places your app in a hibernation state, complete the following steps:\r\n1. (Android 12 and higher only) Enable the hibernation behavior on your device:\r\nadb shell device_config put app_hibernation app_hibernation_enabled true\r\n2. Set the default amount of time that the system waits to enter hibernation. That way, you can restore it after\r\ntesting:\r\nhttps://developer.android.com/topic/performance/app-hibernation\r\nPage 5 of 6\n\nthreshold=$(adb shell device_config get permissions \\\r\n auto_revoke_unused_threshold_millis2)\r\n3. Reduce the amount of time that the system waits. In the following example, the system is modified such\r\nthat your app enters hibernation only one second after you stop interacting with the app:\r\nadb shell device_config put permissions \\\r\n auto_revoke_unused_threshold_millis2 1000\r\n4. Wait for any boot-time broadcasts to finish on your test device by running the following command:\r\nadb shell am wait-for-broadcast-idle\r\nWhen the broadcasts are finished, this command returns the message: All broadcast queues are idle!\r\n5. Invoke the app hibernation process manually:\r\nadb shell cmd jobscheduler run -u 0 -f \\\r\n com.google.android.permissioncontroller 2\r\n6. (Android 12 and higher only) Confirm that the app is hibernated, using one of the following methods:\r\nObserve that the test device now shows a notification, indicating that unused apps are hibernated.\r\nRun the following command:\r\nadb shell cmd app_hibernation get-state PACKAGE-NAME\r\n7. Restore the default amount of time that the system waits before it places your app into hibernation:\r\nadb shell device_config put permissions \\\r\n auto_revoke_unused_threshold_millis2 $threshold\r\nSource: https://developer.android.com/topic/performance/app-hibernation\r\nhttps://developer.android.com/topic/performance/app-hibernation\r\nPage 6 of 6",
	"extraction_quality": 1,
	"language": "EN",
	"sources": [
		"MITRE"
	],
	"origins": [
		"web"
	],
	"references": [
		"https://developer.android.com/topic/performance/app-hibernation"
	],
	"report_names": [
		"app-hibernation"
	],
	"threat_actors": [
		{
			"id": "75108fc1-7f6a-450e-b024-10284f3f62bb",
			"created_at": "2024-11-01T02:00:52.756877Z",
			"updated_at": "2026-04-10T02:00:05.273746Z",
			"deleted_at": null,
			"main_name": "Play",
			"aliases": null,
			"source_name": "MITRE:Play",
			"tools": [
				"Nltest",
				"AdFind",
				"PsExec",
				"Wevtutil",
				"Cobalt Strike",
				"Playcrypt",
				"Mimikatz"
			],
			"source_id": "MITRE",
			"reports": null
		}
	],
	"ts_created_at": 1775434380,
	"ts_updated_at": 1775826774,
	"ts_creation_date": 0,
	"ts_modification_date": 0,
	"files": {
		"pdf": "https://archive.orkl.eu/24fc1d2192dea5d4f9120a4d923364a98286b0ee.pdf",
		"text": "https://archive.orkl.eu/24fc1d2192dea5d4f9120a4d923364a98286b0ee.txt",
		"img": "https://archive.orkl.eu/24fc1d2192dea5d4f9120a4d923364a98286b0ee.jpg"
	}
}