• Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
  • Help Room /
avatar image
6
Question by kingzustin · Jan 12 at 09:49 PM · androidandroid buildgoogle playgoogle play gamesmanifest

'You uploaded an APK or Android App Bundle which has an activity, activity alias, service or broadcast receiver with intent filter, but without 'android:exported' property set.'

Hi there. I'm working on an update to an already-published app on the Google Play Store. After working on my game for a while, I uploaded my .aab build to Google Play Internal Testing, only to have my file rejected by an error saying I didn't set any android:exported properties.

Can anyone help me with this? I think it's an issue with my manifest.xml, but I'm not even certain about that. Even advice on how to start troubleshooting would be awesome!

I've uploaded many builds to Google Play, even ones with more features than this, and this is the first time I've gotten this error.

Thanks!

Platform: Android Unity Version: 2020.3.16f1 Features in my game that may effect this(?): Unity Analytics, Google Play Games Achievements, Leaderboards, and Save Game, Google AdMob, and a plugin called "EasyMobile" from the Unity Asset Store

Full error (as seen in screenshot below): "You uploaded an APK or Android App Bundle which has an activity, activity alias, service or broadcast receiver with intent filter, but without 'android:exported' property set. This file can't be installed on Android 12 or higher. See: developer.android.com/about/versions/12/behavior-changes-12#exported"

alt text

screenshot-2022-01-12-164223.png (64.3 kB)
Comment
Add comment · Show 2
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image kingzustin · Jan 12 at 09:51 PM 0
Share

Sidenote: I don't know how formatting works. Apparently hitting enter for a new line doesn't work? If someone is able to edit it I'd appreciate that!

avatar image ahmedaniss · Feb 05 at 12:23 PM 0
Share

Article to Fix Error You uploaded an APK or Android App Bundle which has an activity : https://forum.unity.com/threads/not-able-to-publish-on-google-play-android-exported-android-12.1224948/#post-7870258

8 Replies

· Add your reply
  • Sort: 
avatar image
4
Best Answer

Answer by PamirKhan · Jan 13 at 12:35 PM

@kingzustin I build my game using Unity 2020.3.24.f1 I got same error when i was uploading my game to play store so i search online and found out that you have to made the following changes to your app in unity if you want to build for android 12.

Project Settings > Player > Android > Publishing Settings > Build, select Custom Main Manifest. Apply the following changes to Assets/Plugins/Android/AndroidManifest.xml:

If present, remove the following comment at the top of the file:

Add the android:exported attribute to the tag:

  <activity android:name="com.unity3d.player.UnityPlayerActivity"
            android:theme="@style/UnityThemeSelector"
            android:exported="true">
      <intent-filter>
          <action android:name="android.intent.action.MAIN" />
          <category android:name="android.intent.category.LAUNCHER" />
      </intent-filter>
      <meta-data android:name="unityplayer.UnityActivity" android:value="true" />
  </activity>
 

Source: https://developers.google.com/ar/develop/unity-arf/android-12-build

Unfortunately solution did not work out for me. So i simply download a newer version Unity 2020.3.25.f1 of unity and there was no error in uploading my game to google play store. It looked like they have fixed that issue in newer version of unity. I hope this will help you resolve your issue.

Best regards Limitless Games Pamir Khan

Comment
Add comment · Show 4 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image kingzustin · Jan 13 at 05:21 PM 0
Share

Thanks! Doing the custom manifest did NOT work for me, but updating the Unity version did!

avatar image kiet57441 · Jan 16 at 08:41 AM 1
Share

it did not working on 2020.3.26f1

avatar image ahmedaniss · Jan 29 at 08:01 AM 0
Share

Problem Fixed here : https://forum.unity.com/threads/not-able-to-publish-on-google-play-android-exported-android-12.1224948/#post-7846305

avatar image miguelmartamate · Mar 29 at 12:13 AM 0
Share

i have waste 7 hours of my life, and this FINALLY fixed the problem, I LOVE YOU

avatar image
0

Answer by segant · Jan 13 at 04:13 PM

Same problem.

Comment
Add comment · Show 4 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image kingzustin · Jan 13 at 05:21 PM 0
Share

See the solution I marked with green. It worked for me!

avatar image segant kingzustin · Jan 13 at 05:29 PM 0
Share

I'm using 2021.1.0b3. Still same. I have to use new shadergraph.

avatar image kingzustin segant · Jan 13 at 05:31 PM 0
Share

Hmm okay, strange then. Maybe this fix was put in since creating the Unity Beta version. However, I don't know and don't know how to fix it... sorry :(

avatar image ahmedaniss · Jan 29 at 08:01 AM 0
Share

Problem Fixed here : https://forum.unity.com/threads/not-able-to-publish-on-google-play-android-exported-android-12.1224948/#post-7846305

avatar image
0

Answer by Voxel-Busters · Jan 14 at 06:52 AM

Most likely the issue is not having exported flag for the unity activity which is a requirement from Android 12. This can be solved by updating your unity to latest version.


BUT,

If you can't update or if unity hasn't back-ported to your LTS version, you can try the script listed here.


Note that this is picked from our plugin Cross Platform Native Plugins : Essential Kit and adapted to avoid any compilation errors for other who don't have the plugin. So, if you already have this plugin, nothing to add.


How to use?

  1. Copy the below script and place it in any Editor folder
  2. Make apk/aab and upload


[3]: http://u3d.as/1szE

Comment
Add comment · Show 3 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image segant · Jan 15 at 07:34 AM 0
Share

I added this script in Assets/Editor path. But after build and uploaded to playstore i got same error. I'm using 2022.1.0b3

avatar image Voxel-Busters segant · Jan 17 at 06:30 AM 0
Share

If it still doesn't work, it means you have other plugins which haven't added exported flag. Try updating those plugins or contact the asset publisher for the same.

avatar image ahmedaniss · Jan 29 at 08:02 AM 0
Share

Problem Fixed here : https://forum.unity.com/threads/not-able-to-publish-on-google-play-android-exported-android-12.1224948/#post-7846305

avatar image
0

Answer by magsoftware · Jan 17 at 01:33 PM

Adding android:export in my AndroidManifest doesn't work but I've found another solution for the moment.

In PlayerSettings -> Others I've changed Target API level from 'Automatic(highest installed)' to Android 11 ( API level 30 ) . If you do not have API 30 installed, use Android Studio -> Tools -> SDK Manager and install it.

If an error still appear when you want to build, go to C: -> Users -> YourUser -> AppData -> Local -> Android -> SDK -> Platforms and select 'android-30' folder.
Copy that folder to C:\Program Files\Unity\Hub\Editor\2021.1.16f1\Editor\Data\PlaybackEngines\AndroidPlayer\SDK\platforms

Restart unity and try to build again.

I know this is not a good solution for building for Android 12 but I'm using it to build just for other versions for the moment.

Cheers!

Comment
Add comment · Show 2 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image ahmedaniss · Jan 29 at 08:02 AM 0
Share

Problem Fixed here : https://forum.unity.com/threads/not-able-to-publish-on-google-play-android-exported-android-12.1224948/#post-7846305

avatar image sonukrshah · Mar 10 at 05:01 PM 0
Share

Thank You!

avatar image
0

Answer by Brownberrygames · Jan 18 at 06:51 PM

This worked for me:

-Updated the unity version from 2019.4.21 to 2020.3.19. Then follow Project Settings > Player > Android > Publishing Settings > Build, select Custom Main Manifest -Added android:exported attribute to the activity tag in Main Manifest

Resolve Dependencies and build, after that I was able to update my game on playstore.

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image ahmedaniss · Jan 29 at 08:02 AM 0
Share

Problem Fixed here : https://forum.unity.com/threads/not-able-to-publish-on-google-play-android-exported-android-12.1224948/#post-7846305

  • 1
  • 2
  • ›

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Welcome to Unity Answers

The best place to ask and answer questions about development with Unity.

To help users navigate the site we have posted a site navigation guide.

If you are a new user to Unity Answers, check out our FAQ for more information.

Make sure to check out our Knowledge Base for commonly asked Unity questions.

If you are a moderator, see our Moderator Guidelines page.

We are making improvements to UA, see the list of changes.



Follow this Question

Answers Answers and Comments

341 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Google Play Game services Resolution Exception with newer Google Repository version 2 Answers

Android build installs without an icon in the app drawer 2 Answers

What is "good" Install/Uninstall rate for growing-good apps? 0 Answers

Google Play Game Services activation success/error checking 0 Answers

Android Manifest: incorrect version number since updating to 2017.4 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges