# Analytics for React Native and Expo apps

Add a few lines and read how your app is doing in plain words: who downloaded it, who paid, what they did and who came back.

Connect your app14 days free. No card, no password.

## Expo

$ npx expo install apparent-expo @react-native-async-storage/async-storage expo-application expo-localization

// Start it in the root layout (app/_layout.tsx) or App.tsx
import { Apparent } from "apparent-expo";

Apparent.init({ apiUrl: "https://in.apparent.fyi", app: "my-app", key: "<your key>" });

// expo-router, in the root layout:
import { useApparentScreens } from "apparent-expo/router";
useApparentScreens();

// The actions that matter
Apparent.track("sign_up");

## React Native

$ npm install apparent-expo @react-native-async-storage/async-storage && npx pod-install

// Start it in index.js or App.tsx
import { Apparent } from "apparent-expo";

Apparent.init({ apiUrl: "https://in.apparent.fyi", app: "my-app", key: "<your key>" });

// React Navigation:
import { apparentScreens } from "apparent-expo/navigation";
import { NavigationContainer, useNavigationContainerRef } from "@react-navigation/native";

const ref = useNavigationContainerRef();
<NavigationContainer ref={ref} {...apparentScreens(ref)}>

// The actions that matter
Apparent.track("sign_up");On npm. Every option: the React Native & Expo docs.

## What you get

- Every screen by itself, in Expo Router or React Navigation.
- Opens, visits, updates and time in the app.
- Purchases tied to what people did first, through RevenueCat.
- Crashes and errors, with the screen and version.
- Store downloads, reviews and sales on the same page.

## Private by default

- No App Tracking Transparency prompt: it never reads the advertising id (IDFA or GAID).
- The IP address is used to tell the country, then dropped. It's never stored.
- One random id per install, made by the SDK. A user id only if you set one.
- No native code: nothing to link, works in Expo Go.
- optOut() stops it, and it's remembered. Your data is never sold or shared.

## Questions

Does it work with bare React Native?

Yes. Only AsyncStorage is required; the Expo modules are used when the app has them.

Does it work in Expo Go?

Yes. The SDK has no native code of its own.

Will events get lost offline?

No. Every event is saved on the phone first, and up to 1,000 wait for a connection.

Do I need the ATT prompt?

No. The SDK never reads the advertising id and nothing it sends is tracking in Apple's sense.

## Other SDKs

- Swift (iOS)
- Kotlin (Android)
- Flutter
- Capacitor & Ionic
- Website
- All SDKs

## Also read

- Expo analytics, without a native build
- Ionic analytics, without Firebase
- App analytics without the ATT prompt
- Privacy-first analytics for mobile apps
- Firebase Analytics alternative
- Store and RevenueCat integrations

## Your app already has a story. Start reading it.

Connect your app14 days free. No card, no password.

apparent

Source: https://apparent.fyi/react-native-analytics
