---
url: https://talkjs.com/docs/UI_Components/React_Native/Installation
---

# Installation

Install the React Native SDK.

Ask a question Copy for LLM [View as Markdown](/docs/UI_Components/React_Native/Installation.md)
Our React Native SDK provides pre-built chat UI components for your React Native application.

You can use the React Native SDK with React Native versions 0.64 and higher.

To install the React Native SDK, you can choose from either of two TalkJS modules, depending on whether you would like to build using [Expo](https://expo.dev/):

| Module | Works with Expo | Works with Expo Go |
| --- | --- | --- |
| [@talkjs/react-native](/docs/UI_Components/React_Native/Installation/#using-talkjsreact-native) | No | No |
| [@talkjs/expo](/docs/UI_Components/React_Native/Installation/#using-talkjsexpo) | Yes | No |

## Using @talkjs/react-native

The `@talkjs/react-native` module allows you to build React Native apps fast.

Because some of its dependencies are incompatible with Expo, `@talkjs/react-native` is not suited for building on Expo. If you would like to build React Native apps using Expo, you can [use @talkjs/expo](/docs/UI_Components/React_Native/Installation/#using-talkjsexpo) instead.

### Installation

Install the React Native SDK into your app from the command line. To ensure that the module can be loaded correctly, make sure also to explicitly install the SDK's peer dependencies, as follows (with either your npm or yarn package manager):

**Note:** React Native CLI doesn't auto-link libraries with native modules when those libraries are transitive dependencies. To load the native modules correctly, you instead have to explicitly install the SDK's peer dependencies as shown in the following.

**npm:**

```bash
npm install @talkjs/react-native @notifee/react-native @react-native-community/push-notification-ios @react-native-firebase/app @react-native-firebase/messaging react-native-webview @react-native-async-storage/async-storage
```

**yarn:**

```bash
yarn add @talkjs/react-native @notifee/react-native @react-native-community/push-notification-ios @react-native-firebase/app @react-native-firebase/messaging react-native-webview @react-native-async-storage/async-storage
```

If you are targeting iOS, you'll also need to add the following to your `Podfile` in your app's `target` section:

```ruby
pod 'Firebase', :modular_headers => true
pod 'FirebaseCore', :modular_headers => true
pod 'GoogleUtilities', :modular_headers => true
$RNFirebaseAsStaticFramework = true
```

Afterwards, run:

```bash
npx pod-install
```

### Usage

To import the React Native library into your project, add one of the following statements to your app's code, depending on what module system you are using:

**ES6/TypeScript:**

```js
import * as TalkjsRn from '@talkjs/react-native';
```

**CommonJS:**

```js
const TalkjsRn = require('@talkjs/react-native');
```

Once you have imported the library, to start using TalkJS in your project, follow the [React Native getting started guide](/docs/UI_Components/React_Native/).

## Using @talkjs/expo

The `@talkjs/expo` module allows you to build React Native apps fast on Expo. The module does not contain native code and it relies on dependencies that support Expo.
This means that you can use it to build with Expo.

Because some of its dependencies contain native code, `@talkjs/expo` does not work with Expo Go.

### Installation

Install the React Native SDK and its dependencies from the command line, as follows:

```bash
expo install @talkjs/expo @notifee/react-native react-native-webview @react-native-async-storage/async-storage expo-build-properties
```

### Configure Notifee

This step is required for Expo users even if you don't plan to enable push notifications, otherwise building on Android will fail.

The `Notifee` package requires its native modules to be defined under `extraMavenRepos` in your project's `app.json` as shown:

JSON

```json
{
  "expo": {
    "plugins": [
      // Other plugins
      [
        "expo-build-properties",
        {
          "android": {
            "extraMavenRepos": [
              "../../node_modules/@notifee/react-native/android/libs"
            ]
          }
        }
      ]
    ]
  }
}
```

### Usage

To import the React Native library into your project, add one of the following statements to your code, depending on what module system you are using:

**ES6/TypeScript:**

```js
import * as TalkjsRn from '@talkjs/expo';
```

**CommonJS:**

```js
const TalkjsRn = require('@talkjs/expo');
```

Once you have imported the library, to start using TalkJS in your project, follow the [React Native getting started guide](/docs/UI_Components/React_Native/).

## Beta release

Both `@talkjs/react-native` and `@talkjs/expo` are released in a beta state. This is because currently, the React Native SDK does not yet have all the features that are available in the TalkJS JavaScript SDK. As soon as the React Native SDK parallels the features available in the JavaScript SDK, we will release version 1.0.0 of the packages.

That said, we always maintain backward compatibility, so both packages are stable for production use.