Fix for READ_SMS permission on Android for Google Play’s new policy

Hi Expo team,
We’ve received Google Play’s new policy regarding removing READ_SMS permission moving forward.
Our current app is version 24.0.0 and doesn’t use Expo.SMS API.
Is there a fix that would be compatible with our version? Thanks

Heya,

You’ll want to add the permissions you need manually in your app.json. Without specifying them explicitly, you get the default list which includes READ_SMS. Check out the documentation to see the format and the list of permissions you might need. (I linked the 28.0.0 docs because the format is nicer but it’s just the same for 24.0.0.)

e.g. if you use the camera you need “CAMERA”, if you use the filesystem you need “READ_EXTERNAL_STORAGE” and “WRITE_EXTERNAL_STORAGE”, etc. Specifically, the “android” section of your app.json should look something like this:

    "android": {
      "package": "com.my.package",
      "permissions": [
        "CAMERA",
        "MANAGE_DOCUMENTS",
        "READ_EXTERNAL_STORAGE",
        "WRITE_EXTERNAL_STORAGE"
      ],
      "versionCode": 6
    },

Then you can re-build it and publish to the app store!

1 Like

Thanks @seveneightn9ne. We’ll give it a try!

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.