[Fix] You uploaded an APK or Android App Bundle which has an activity, activity alias, service, or broadcast receiver with intent filter, but without the ‘android: exported’ property set. This file can’t be installed on Android 12 or higher

The problem “This file can’t be installed on Android 12 or higher” is seen when you are working on google play store apps and have recently uploaded an APK or Android App Bundle without the “android: exported” property set, which contains an activity, activity alias, service, or broadcast receiver with intent filter.

Given below is the snippet of error:

You uploaded an APK or Android App Bundle which has an activity, activity alias, service, or broadcast receiver with intent filter, but without the 'android: exported' property set. This file can't be installed on Android 12 or higher.

This file can't be installed on Android 12 or higher

Error “This file can’t be installed on Android 12 or higher” is seen because you have recently submitted an APK or Android App Bundle that has an intent filter on an activity, activity alias, service, or broadcast receiver, but without setting the ‘android: exported’ attribute.

To fix the error “This file can’t be installed on Android 12 or higher“, add the android: exported in the main manifest file, this should help you fix your error.

Alternatively you can preview using the merged manifest by using the proper steps. If the preview is still not visible, you will need to use the links provided for each manifest file to access the individual manifest files from the various third-party libraries you used in your project.

Steps to Fix the problem “This file can’t be installed on Android 12 or higher” Android Studio:

Google’s new policy states You must explicitly declare the android:exported: true attribute for any activities, services, or broadcast receivers that employ intent filters if your app is designed for Android versions 12 or higher and incorporates them.

Check all the activities, services, and receivers that can utilise intent-filter but lack the android: exported tag in the main manifest file. For example these tags, include android:exported=”true” or android:exported=”false.”

When should you add android:exported=”true” or android:exported=”false” to activities, services, or broadcast receivers that make use of intent filters, is the natural question which comes up following the above solution.

Set android: exported to true if the app component has the LAUNCHER category. Set android: exported to false if not.

In case the above solution does not work for you then you will have to follow the steps mentioned below to for an alternative fix:

Step 1: The first step is to select Merged Manifest at the bottom of the AndroidManifest.xml file after opening it. as in the image shown below:

Error: This file can’t be installed on Android 12 or higher

Step 2: In your build, if you are unable to preview the combined manifest. Try to open the merged manifest once again after setting the gradle file to compileSdkVersion 30 and targetSdkVersion 30 and synchronising your project.

if still, you cannot see the preview then you will have to access the individual manifest files from the various third-party libraries you utilised in your project by using the links provided for each manifest file.

Note: You should also examine the manifest files for each third-party library to see whether any activities, services, or receivers are being used.

If so, you must use the android: exported property to override those activities, services, or receivers in your main manifest file.

Conclusion

Add the android: exported to the main manifest file to correct the error that reads “This file can’t be installed on Android 12 or higher.” Alternately, by following the right procedures, you can preview using the merged manifest.

If the preview is still not accessible, you must visit the specific manifest files from each of the different third-party libraries you used in your project using the links that are supplied for each manifest file.