You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The error TOO_MANY_REGISTRATIONS in Firebase Cloud Messaging (FCM) happens when too many tokens (device registrations) are created for the same app on a single device. Google enforces a limit of 10 token registrations per device to prevent abuse.
Possible Causes:
Frequent Uninstall/Reinstall of the App
Each time you reinstall the app, a new FCM token is generated.
If done too many times, the limit is reached.
Multiple Firebase Instances in the App
If the app is calling FirebaseMessaging.getInstance().getToken() too frequently, it can cause excessive registrations.
Device Used for Testing Many Apps
If you're using a test device with multiple FCM-integrated apps, it may hit the token limit.
Token Not Properly Deleted on Uninstall
Firebase doesn’t automatically delete tokens when the app is uninstalled.
If not handled properly, old tokens accumulate and reach the limit.
Steps to reproduce?
on app first launch
What did you expect to happen?
normal device registration
OneSignal Android SDK version
5.1.24
Android version
15
Specific Android models
Nothing Phone 1
Relevant log output
Error Getting FCM Token
java.lang.Exception: java.io.IOException: java.util.concurrent.ExecutionException: java.io.IOException: TOO_MANY_REGISTRATIONS
at com.onesignal.notifications.internal.registration.impl.PushRegistratorAbstractGoogle.attemptRegistration(PushRegistratorAbstractGoogle.kt:154)
at com.onesignal.notifications.internal.registration.impl.PushRegistratorAbstractGoogle.registerInBackground(PushRegistratorAbstractGoogle.kt:108)
at com.onesignal.notifications.internal.registration.impl.PushRegistratorAbstractGoogle.internalRegisterForPush(PushRegistratorAbstractGoogle.kt:84)
at com.onesignal.notifications.internal.registration.impl.PushRegistratorAbstractGoogle.registerForPush$suspendImpl(PushRegistratorAbstractGoogle.kt:73)
at com.onesignal.notifications.internal.registration.impl.PushRegistratorAbstractGoogle.registerForPush(Unknown Source:0)
at com.onesignal.notifications.internal.pushtoken.PushTokenManager.retrievePushToken(PushTokenManager.kt:31)
at com.onesignal.notifications.internal.listeners.DeviceRegistrationListener$retrievePushTokenAndUpdateSubscription$1.invokeSuspend(DeviceRegistrationListener.kt:71)
at com.onesignal.notifications.internal.listeners.DeviceRegistrationListener$retrievePushTokenAndUpdateSubscription$1.invoke(Unknown Source:8)
at com.onesignal.notifications.internal.listeners.DeviceRegistrationListener$retrievePushTokenAndUpdateSubscription$1.invoke(Unknown Source:2)
at com.onesignal.common.threading.ThreadUtilsKt$suspendifyOnThread$1$1.invokeSuspend(ThreadUtils.kt:70)
at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:104)
at kotlinx.coroutines.EventLoopImplBase.processNextEvent(EventLoop.common.kt:277)
at kotlinx.coroutines.BlockingCoroutine.joinBlocking(Builders.kt:95)
at kotlinx.coroutines.BuildersKt__BuildersKt.runBlocking(Builders.kt:69)
at kotlinx.coroutines.BuildersKt.runBlocking(Unknown Source:1)
at kotlinx.coroutines.BuildersKt__BuildersKt.runBlocking$default(Builders.kt:48)
at kotlinx.coroutines.BuildersKt.runBlocking$default(Unknown Source:1)
at com.onesignal.common.threading.ThreadUtilsKt$suspendifyOnThread$1.invoke(ThreadUtils.kt:69)
at com.onesignal.common.threading.ThreadUtilsKt$suspendifyOnThread$1.invoke(ThreadUtils.kt:67)
at kotlin.concurrent.ThreadsKt$thread$thread$1.run(Thread.kt:30)
Caused by: java.io.IOException: java.util.concurrent.ExecutionException: java.io.IOException: TOO_MANY_REGISTRATIONS
at com.google.firebase.messaging.FirebaseMessaging.blockingGetToken(FirebaseMessaging.java:626)
at com.google.firebase.messaging.FirebaseMessaging.lambda$getToken$4$com-google-firebase-messaging-FirebaseMessaging(FirebaseMessaging.java:382)
at com.google.firebase.messaging.FirebaseMessaging$$ExternalSyntheticLambda6.run(D8$$SyntheticClass:0)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:487)
at java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:307)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:644)
at com.google.android.gms.common.util.concurrent.zza.run(com.google.android.gms:play-services-basement@@18.3.0:2)
at java.lang.Thread.run(Thread.java:1012)
Caused by: java.util.concurrent.ExecutionException: java.io.IOException: TOO_MANY_REGISTRATIONS
at com.google.android.gms.tasks.Tasks.zza(com.google.android.gms:play-services-tasks@@18.1.0:5)
at com.google.android.gms.tasks.Tasks.await(com.google.android.gms:play-services-tasks@@18.1.0:9)
at com.google.firebase.messaging.FirebaseMessaging.blockingGetToken(FirebaseMessaging.java:624)
at com.google.firebase.messaging.FirebaseMessaging.lambda$getToken$4$com-google-firebase-messaging-FirebaseMessaging(FirebaseMessaging.java:382)
at com.google.firebase.messaging.FirebaseMessaging$$ExternalSyntheticLambda6.run(D8$$SyntheticClass:0)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:487)
at java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:307)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:644)
at com.google.android.gms.common.util.concurrent.zza.run(com.google.android.gms:play-services-basement@@18.3.0:2)
at java.lang.Thread.run(Thread.java:1012)
Caused by: java.io.IOException: TOO_MANY_REGISTRATIONS
at com.google.firebase.messaging.GmsRpc.handleResponse(GmsRpc.java:309)
2025-03-21 02:42:21.045 12127-12510 OneSignal com.domain.app E at com.google.firebase.messaging.GmsRpc.lambda$extractResponseWhenComplete$0$com-google-firebase-messaging-GmsRpc(GmsRpc.java:320)
at com.google.firebase.messaging.GmsRpc$$ExternalSyntheticLambda0.then(D8$$SyntheticClass:0)
at com.google.android.gms.tasks.zzc.run(com.google.android.gms:play-services-tasks@@18.1.0:3)
at androidx.privacysandbox.ads.adservices.adid.AdIdManager$Api33Ext4Impl$$ExternalSyntheticLambda0.execute(D8$$SyntheticClass:0)
at com.google.android.gms.tasks.zzd.zzd(com.google.android.gms:play-services-tasks@@18.1.0:1)
at com.google.android.gms.tasks.zzr.zzb(com.google.android.gms:play-services-tasks@@18.1.0:5)
at com.google.android.gms.tasks.zzw.zzb(com.google.android.gms:play-services-tasks@@18.1.0:3)
at com.google.android.gms.tasks.zzc.run(com.google.android.gms:play-services-tasks@@18.1.0:8)
at com.google.android.gms.cloudmessaging.zzy.execute(Unknown Source:0)
at com.google.android.gms.tasks.zzd.zzd(com.google.android.gms:play-services-tasks@@18.1.0:1)
at com.google.android.gms.tasks.zzr.zzb(com.google.android.gms:play-services-tasks@@18.1.0:5)
at com.google.android.gms.tasks.zzw.zzb(com.google.android.gms:play-services-tasks@@18.1.0:3)
at com.google.android.gms.tasks.TaskCompletionSource.setResult(com.google.android.gms:play-services-tasks@@18.1.0:1)
at com.google.android.gms.cloudmessaging.zzr.zzd(com.google.android.gms:play-services-cloud-messaging@@17.1.0:3)
at com.google.android.gms.cloudmessaging.zzt.zza(com.google.android.gms:play-services-cloud-messaging@@17.1.0:2)
at com.google.android.gms.cloudmessaging.zzk.handleMessage(com.google.android.gms:play-services-cloud-messaging@@17.1.0:14)
at android.os.Handler.dispatchMessage(Handler.java:103)
at android.os.Looper.loopOnce(Looper.java:258)
at android.os.Looper.loop(Looper.java:356)
at android.app.ActivityThread.main(ActivityThread.java:8837)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:598)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:896)
Code of Conduct
I agree to follow this project's Code of Conduct
The text was updated successfully, but these errors were encountered:
What happened?
The error TOO_MANY_REGISTRATIONS in Firebase Cloud Messaging (FCM) happens when too many tokens (device registrations) are created for the same app on a single device. Google enforces a limit of 10 token registrations per device to prevent abuse.
Possible Causes:
Frequent Uninstall/Reinstall of the App
Each time you reinstall the app, a new FCM token is generated.
If done too many times, the limit is reached.
Multiple Firebase Instances in the App
If the app is calling FirebaseMessaging.getInstance().getToken() too frequently, it can cause excessive registrations.
Device Used for Testing Many Apps
If you're using a test device with multiple FCM-integrated apps, it may hit the token limit.
Token Not Properly Deleted on Uninstall
Firebase doesn’t automatically delete tokens when the app is uninstalled.
If not handled properly, old tokens accumulate and reach the limit.
Steps to reproduce?
What did you expect to happen?
normal device registration
OneSignal Android SDK version
5.1.24
Android version
15
Specific Android models
Relevant log output
Code of Conduct
The text was updated successfully, but these errors were encountered: