Userbubble
SdksReact native

Installation

Install the Userbubble React Native SDK

The React Native SDK is not yet published to npm. It's coming soon. The documentation below is a preview of the upcoming API.

Choose Your Platform

Expo Projects

For Expo projects, install the SDK along with expo-secure-store:

npx expo install @userbubble/react-native expo-secure-store

The SDK will automatically detect Expo and use expo-secure-store for secure data storage.

Bare React Native Projects

For bare React Native projects, install the SDK with AsyncStorage:

npm install @userbubble/react-native @react-native-async-storage/async-storage

Or with yarn:

yarn add @userbubble/react-native @react-native-async-storage/async-storage

The SDK will automatically detect bare React Native and use AsyncStorage.

Get Your API Key

Before using the SDK, you'll need an API key:

  1. Go to your organization settings in Userbubble
  2. Navigate to "API Keys"
  3. Click "Generate New Key"
  4. Copy the API key (it starts with ub_live_ or ub_test_)

Store your API key securely in environment variables. Never commit it to your repository.

Environment Variables

For Expo:

Add to your .env file:

EXPO_PUBLIC_USERBUBBLE_API_KEY=ub_live_xxxxxxxxxxxxx

For bare React Native:

Add to your .env file and use a package like react-native-dotenv:

USERBUBBLE_API_KEY=ub_live_xxxxxxxxxxxxx

Next Steps

Now that you've installed the SDK, continue to the Quick Start guide to integrate it into your app.

On this page