React Navigation crashes: requireNativeComponent RNSScreenStackHeaderConfig was not found
requireNativeComponent: "RNSScreenStackHeaderConfig" was not found in the UIManagerShort answer
The native part of react-native-screens is missing from the app you are running. Either the package is not installed, or it was added after the last native build so the running binary does not contain it. Install it the right way for Expo or bare React Native, run pod install on iOS, and rebuild the app.
Fix it fast
1Find out which cause you have
Check that react-native-screens is a dependency and see which version is installed.
npm ls react-native-screens2Match what you see, then jump to its fix
What does the error look like?
requireNativeComponent: "RNSScreenStackHeaderConfig" was not found in the UIManagerrequireNativeComponent: "RNSScreen" was not found in the UIManagerViewManager returned null for either RNSScreen or RCTRNSScreen
Cause 1 of 2
react-native-screens is not installed
1Check
React Navigation lists react-native-screens and react-native-safe-area-context as required install steps. Look in package.json.
grep -n "react-native-screens\|react-native-safe-area-context" package.json2Fix
In an Expo project install with npx expo install so the version fits your SDK. In a bare project use npm install.
# Expo
npx expo install react-native-screens react-native-safe-area-context
# bare React Native
npm install react-native-screens react-native-safe-area-context3Verify
npm ls shows one version of each package.
npm ls react-native-screens react-native-safe-area-contextConfirmed by reactnavigation.org
Cause 2 of 2
The native app was not rebuilt or pods are not installed
1Check
React Navigation says missing native views mean the package is missing or the app was not rebuilt. A JavaScript reload does not add native code to an installed app.
ls ios/Pods 2>/dev/null | head -n 32Fix
On macOS run pod install in ios/, then clear the Metro cache and rebuild the app. In Expo, rebuild the native app after installing native packages too.
cd ios && pod install && cd ..
npx react-native start --reset-cache
npx react-native run-android # or run-ios3Verify
The app opens on the first screen of your stack without the red error.
npx react-native run-androidConfirmed by reactnavigation.org
How do I stop it coming back?
- After adding any package that has native code, rebuild the app instead of only reloading JavaScript.
- Install with npx expo install in Expo so library versions match the SDK.
- Run pod install after dependency changes on iOS.
Sources
How was this page made?
I drafted this page with AI assistance from the official documents listed under Sources. Every cause above names the document that confirms it. I have not reproduced this fix on a machine of my own yet, so read it as documented guidance, not a test report. Found a mistake? Tell me.
Which stack is behind this page?
Projects of mine built on the same technologies:
- TaxiDexMy own multi-tenant taxi dispatch SaaS: API, dispatcher portal, driver and passenger apps, and the servers underneath.
- QistLockA NestJS and React SaaS driving an Android Device Owner agent that locks financed phones when payments lapse.
- TaskvareA task and project-management suite: React on the web, Flutter on mobile, TypeScript underneath.
Related fixes
Mobile apps
Android build stops at processDebugManifest in a React Native app
Manifest merger failed
processDebugManifest is the step that merges your AndroidManifest.xml with the manifests of every library.
2 causes, each with a fixMobile apps
Running pod on a React Native project fails with can't find gem cocoapods
can't find gem cocoapods (>= 0.a) with executable pod
The pod command exists, but the Ruby that is running it has no CocoaPods gem.
3 causes, each with a fixMobile apps
React Native Android build cannot find the foojay-resolver-convention plugin
Plugin [id: 'org.gradle.toolchains.foojay-resolver-convention'] was not found in any of the following sources:
The foojay plugin is a settings plugin that Gradle downloads from the Plugin Portal.
3 causes, each with a fixMobile apps
Kotlin and Java compile to different JVM targets in a React Native Android build
'compileJava' task (current target is 1.8) and 'compileKotlin' task (current target is 11)
Gradle refuses to build when the Java task and the Kotlin task target different JVM versions.
3 causes, each with a fixMobile apps
Gradle cannot run node in a React Native Android build
Process 'command 'node'' finished with non-zero exit value 1
The React Native Gradle plugin starts node for bundling.
3 causes, each with a fixMobile apps
The Android emulator opens the app but never connects to Metro or Expo
Metro bundler ECONNREFUSED 127.0.0.1:19001
When the emulator cannot reach Metro, first prove each side on its own: adb sees the emulator, and Metro listens on its port.
4 causes, each with a fix