Installation
Set up React Native Native in your Expo project.
Prerequisites
- Node.js 18+
- Expo CLI (
npx expo) - iOS: Xcode 16+ with Command Line Tools
- Android: Android Studio with NDK installed (optional, Rust and C++ only)
- Rust (optional):
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
Quick start
The fastest way to get started — a pre-configured Expo template with a C++ example:
npx create-expo-app my-app --template @react-native-native/template-starter
cd my-appThis includes metro.config.js, tsconfig.json, .gitignore, and a hello.cpp example ready to go. Skip to Build and run.
Add to an existing project
npx expo install @react-native-native/nativ-fabricConfigure native builds
Add the config plugin to your app.json:
{
"expo": {
"plugins": [
"@react-native-native/nativ-fabric"
]
}
}Build and run
Create a Development Build locally or via EAS:
# Local build — iOS
npx expo run:ios
# Local build — Android
npx expo run:android
# Or via EAS Build
eas build --profile developmentOnce the build is installed, start Metro:
npx expo startThat's it. You're ready to write native code.
Setup wizard
Run the interactive setup to configure toolchains for the languages you want to use:
npx nativ setupThis asks which platforms and languages you need, then installs the required toolchains. You can also run individual setup commands directly:
npx nativ setup rust # Rust targets + Cargo.toml
npx nativ setup kotlin # Kotlin compiler toolchain
npx nativ setup compose # Jetpack Compose (includes Kotlin)C++ and Swift require no additional setup — Xcode and the Android NDK provide everything needed.
Use --platform to limit setup to a single platform:
npx nativ setup rust --platform iosAfter setup, run doctor to verify everything is configured correctly:
npx nativ doctorSee Troubleshooting for common issues.
Expo compatibility
React Native Native requires a Development Build — a custom-compiled version of your app that includes the native runtime. This works on both physical devices and simulators.
Expo Go is not supported. Expo Go is a pre-built app that can't load custom native code.
| Environment | Supported |
|---|---|
| Development Build (physical device) | Yes |
| Development Build (simulator/emulator) | Yes |
| EAS Build | Yes |
| Expo Go | No |
If you're used to Expo Go, the switch to Development Builds is a one-time setup — after that the workflow is identical, with the added ability to run native code.