Skip to main content
Quick Reference for AI Agents & Developers
  • Not code-only. iOS needs a VoIP .p12 certificate + a native PushKit/CallKit module; Android needs Firebase + a self-managed ConnectionService
  • On iOS you must call reportNewIncomingCall for every VoIP push — the OS terminates an app that does not
  • Skipping the logout unregister leaves the next user on that device receiving the previous user’s calls
  • PrerequisiteRinging covers the foreground half
Implement VoIP push notifications to receive incoming calls even when your app is in the background or terminated. This requires platform-specific configuration for iOS CallKit and Android ConnectionService.

iOS VoIP Configuration

Enable VoIP Push Notifications

  1. In Xcode, select your target
  2. Go to Signing & Capabilities
  3. Add Push Notifications capability
  4. Add Background Modes capability
  5. Enable Voice over IP

Create VoIP Certificate

  1. Go to Apple Developer Portal
  2. Navigate to Certificates, Identifiers & Profiles
  3. Create a new VoIP Services Certificate
  4. Download and install the certificate
  5. Export the .p12 file for your server

Configure CometChat Dashboard

  1. Go to your CometChat Dashboard
  2. Navigate to Notifications > Push Notifications
  3. Upload your VoIP certificate (.p12 file)
  4. Configure the certificate password

Implement CallKit

Create a native module to handle CallKit:

Android VoIP Configuration

Add Firebase Cloud Messaging

  1. Add Firebase to your Android project
  2. Add the FCM dependency to android/app/build.gradle:

Configure CometChat Dashboard

  1. Go to your CometChat Dashboard
  2. Navigate to Notifications > Push Notifications
  3. Upload your Firebase Server Key

Implement ConnectionService

Create a ConnectionService for incoming calls:

Register ConnectionService

Add to AndroidManifest.xml:

Add Permissions

Register Push Token

Register the VoIP/FCM token with CometChat using CometChatNotifications.registerPushToken. iOS VoIP is its own platform — APNS_REACT_NATIVE_VOIP, distinct from the APNS_REACT_NATIVE_DEVICE used for ordinary message notifications — so an app that both rings and notifies registers two tokens.
Register the token after the user logs in — a token registered with no logged-in user is attached to nobody. Re-register when the token refreshes.providerId is the Provider ID you configured in Dashboard → Notifications → Push Notifications (for example APNS_PROVIDER_ID). Pass it so the token is bound to the right provider.

Unregister on Logout

Release the token when the user logs out, or the next user on that device receives their calls:

Handle Incoming VoIP Push