React Native wrapper for Based off of intercom-cordova.

Installation Guide

  1. Add pod 'Intercom' to ios/Podfile and then run pod install in the ios directory to install the cocoapod.

  2. Open ios/Podfile and add pod 'Intercom'. It will look something like this:

    platform :ios, '9.2'
    target 'YOUR_APP_NAME' do
      # Add Intercom here…
      pod 'Intercom'
  3. In the ios directory, run pod install to install the cocoapod.

  4. Run npm install react-native-intercom (or yarn add react-native-intercom).

  5. Run react-native link to link the package.

    This will perform some of the linking of react-native-intercom. This includes adding pod 'react-native-intercom', :path => '../node_modules/react-native-intercom' to ios/Podfile. In the future the link command can be added to do more of the steps in this installation guide.

  6. Manually Link the library in Xcode (Linking librarys on iOS)

    1. Open Xcode -> Right click "[Your Project Name]/Libraries" folder and select "Add File to [Your Project Name]" -> Select RNIntercom.xcodeproj located in node_modules/react-native-intercom/iOS.
    2. Open "General Settings" -> "Build Phases" -> "Link Binary with Libraries" and add libRNIntercom.a
  7. Config for iOS (intercom-ios)

    1. Add #import "Intercom/intercom.h" with the other imports at the top of ios/YOUR_PROJECT/AppDelegate.m.

    2. Initialize Intercom in ios/YOUR_PROJECT/AppDelegate.m with your Intercom iOS API Key and your Intercom App ID:

      - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
          // Initialize Intercom
          [Intercom setApiKey:@"YOUR_IOS_API_KEY_HERE" forAppId:@"YOUR_APP_ID_HERE"];
    3. Optional, Intercom's documentation suggests adding the following call in order to receive push notifications for new messages:

      - (void)application:(UIApplication *)application didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken {
          [Intercom setDeviceToken:deviceToken];
    4. Optional, allow access to phots on iOS. Open Info.plist in Xcode and add a new key "Privacy - Photo Library Usage Description". Or alternately, open ios/YOUR_PROJECT/Info.plist and add:

        ...other configuration here...
        <string>Send photos to help resolve app issues</string>
        ...other configuration here...
  8. Config for Android (intercom-android)

    1. In android/app/src/main/java/com/YOUR_APP/app/, add the following code in the respective sections of the file using your Intercom Android API Key and Intercom App ID:

      // ...other configuration here...
      import com.robinpowered.react.Intercom.IntercomPackage;
      public class MainApplication extends Application {
        public void onCreate() {
          Intercom.initialize(this, "YOUR_ANDROID_API_KEY_HERE", "YOUR_APP_ID_HERE");
          // ...other configuration here...
        public List<ReactPackage> getPackages() {
          return Arrays.<ReactPackage>asList(
            // ...other configuration here...
            new IntercomPackage()
            // ...other configuration here...
    2. In android/app/src/main/AndroidManifest.xml, add the following code in the respective sections of the file:

      <?xml version="1.0" encoding="utf-8"?>
      <manifest package="com.myapp"
        ...other configuration here...
          ...other configuration here...
          <!-- ...other configuration here... -->
                <action android:name=""/>
            android:exported="true" />
    3. In android/build.gradle add maven { url "" } (h/t):

      allprojects {
        repositories {
          //...other configuration here...
          maven { url "" }
    4. Decide which type of push messaging you want to install, and add choosen method to android/app/build.gradle. If "Google Cloud Messaging (GCM)", then:

      dependencies {
        //...other configuration here...
        compile ''
  9. Import Intercom and use methods

    import Intercom from 'react-native-intercom';
    // or…
    // var Intercom = require('react-native-intercom');
    Intercom.registerIdentifiedUser({ userId: 'Bob' });
    Intercom.logEvent('viewed_screen', { extra: 'metadata' });
    // of your file...

    Note that calling Intercom.registerIdentifiedUser({ userId: 'Bob' }) (or Intercom.registerUnidentifiedUser()) is required before using methods which require that Intercom know the current user… such as Intercom.displayMessageComposer(), etc.


Import or Require the module

import Intercom from 'react-native-intercom';


var Intercom = require('react-native-intercom');

Log an event

Intercom.logEvent('viewed_screen', { extra: 'metadata' });

Register a Logged In user

Intercom.registerIdentifiedUser({ userId: 'bob' });

Register Unidentified user


Register a Logged In user and post extra metadata

Intercom.registerIdentifiedUser({ userId: 'bob' })
    // Pre-defined user attributes
    email: '[email protected]',
    user_id: 'user_id',
    name: 'your name',
    phone: '010-1234-5678',
    language_override: 'language_override',
    signed_up_at: 1004,
    unsubscribed_from_emails: true,
    companies: [{
        // Only supported for iOS now
        // Parameters: IntercomUserAttribtesBuilder.m -> companyForDictionary()
    custom_attributes: {
        my_custom_attribute: 123

Set User Hash for Identity Validation (optional)


Sign Out


Show Message Composer


Show Message Composer with an Initial Message

Intercom.displayMessageComposerWithInitialMessage('Initial Message');

Set Bottom Padding


Listen for Unread Conversation Notifications

componentDidMount() {
  Intercom.addEventListener(Intercom.Notifications.UNREAD_COUNT, this._onUnreadChange)

componentWillUnmount() {
  Intercom.removeEventListener(Intercom.Notifications.UNREAD_COUNT, this._onUnreadChange);

_onUnreadChange = ({ count }) => {

Send FCM token directly to Intercom

  .then((token) => {
    console.log('Device FCM Token: ', token);