iOS push token is not generated

Please provide the following:

  1. SDK Version: 35
  2. Platforms(Android/iOS/web/all): iOS

I’ve been storing pushTokens for each user who logs into my app in a DB. When looking at devices only Android’s are being generated. I created a catch for when running in a simulator.

try {
    token = await Notifications.getExpoPushTokenAsync()
  } catch {
    console.log('SETTING TOKEN TO XXXXXX for simulator')
    token = 'XXXXXX'
  }

Problem is every single iOS device is now XXXXXX

Is there something specific for iOS I’m missing here?

Thanks

I’m assuming you performed Permissions.askAsync(Permissions.NOTIFICATIONS)?

Yes I did have that in place. I figured out the issue as it looks like it was the provisioning profile.

I ran another build with the below after removing the profile in the apple portal.

expo build:ios --clear-provisioning-profile

and can finally see iOS devices generating the push tokens. thanks

1 Like

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