Knowledge Base   /   Computer Codes   /   Android Codes

Google play store not allowed this : MANAGE_EXTERNAL_STORAGE Please provide any other alternate...

Posted on 09 October 2023 01:55 am

Starting from Android 11, the MANAGE_EXTERNAL_STORAGE permission is restricted due to the Scoped Storage feature that enhances app security and user privacy. To comply with these changes, it's recommended to follow the new storage access guidelines.

If your app needs to access files from external storage, consider the following alternatives:

  1. MediaStore API: Use the MediaStore API to access media files like images, audio, and videos. This provides secure access to media files without requesting special permissions.

  2. Storage Access Framework (SAF): Implement SAF to allow users to select files using the system file picker. This enables your app to access files in a way that respects user privacy and permissions.

  3. Internal Storage: Store app-specific files in the app's private storage directory, which doesn't require any special permissions. Use Context.getFilesDir() or Context.getCacheDir().

  4. Shared Storage: If you need to share files between your app and other apps, use the ACTION_OPEN_DOCUMENT intent to allow users to select files.

Remember to update your app to follow the latest Android guidelines and ensure compliance with the changes introduced for storage access in Android 11 and later versions.