Reference

Scoped Storage Internals

Scoped storage is the Android storage model, introduced in Android 10 and enforced from Android 11, that limits an app's direct filesystem access to its own package directories and the shared media collections. Other apps' files and arbitrary paths are reached only through MediaStore, the Storage Access Framework, or special permissions.

Android developmentAndroid

Scoped Storage Internals

Also known as: scoped storage details, android 10 storage

Scoped storage is the Android storage model, introduced in Android 10 and enforced from Android 11, that limits an app's direct filesystem access to its own package directories and the shared media collections. Other apps' files and arbitrary paths are reached only through MediaStore, the Storage Access Framework, or special permissions.

  • Introduced in Android 10 (API 29) and enforced for apps targeting Android 11 (API 30).
  • Apps freely access only their own package directories and media they created.
  • Deleting media an app didn't author needs createDeleteRequest user confirmation on Android 11+.

What scoped storage restricts

Under scoped storage an app gets unrestricted access only to its app-specific directories (`getExternalFilesDir`, `getExternalCacheDir`) plus the media it created. Reading other apps' media requires the READ_MEDIA_IMAGES / READ_MEDIA_VIDEO / READ_MEDIA_AUDIO permissions (Android 13+) or the legacy READ_EXTERNAL_STORAGE on older releases. Raw paths under `/storage/emulated/0` outside these zones are not directly accessible.

Android 11 (API 30) enforced this for apps targeting API 30+, and `requestLegacyExternalStorage` no longer works there. The filesystem is presented through indexed collections: MediaStore for images, video, audio, and Downloads, with each entry exposed as a content URI rather than a `File`.

Escape hatches and how a cleaner operates

To reach files beyond its sandbox a cleaner has three paths: query and modify media via MediaStore (using `createDeleteRequest` / `createTrashRequest` so the system prompts the user for deletions it did not author), browse arbitrary folders via the Storage Access Framework directory picker, or hold MANAGE_EXTERNAL_STORAGE (All files access) for broad read/write on most of shared storage.

MediaStore deletions of files an app did not create return a RecoverableSecurityException on older versions or require the batched `createDeleteRequest` user confirmation on Android 11+. This consent model is why a storage cleaner asks the user to approve bulk photo/video deletions rather than removing them silently.

Related terms

Keep reading the reference.

Act on it

Guides and tools for this topic.