Firebase core module was not found natively on Android

Hi
I’m trying to run the Instamobile React Native Starter kit template and I’m getting this error

“Firebase core module was not found natively on Android” message. It also says to ensure that the dependencies have been added correctly. The build.gradle file references Firebase (see below), but I don’t know how to tell if it is correct.

implementation "com.google.firebase:firebase-core:16.0.3"
implementation "com.google.firebase:firebase-auth:16.0.3"
implementation "com.google.firebase:firebase-firestore:17.1.0"
implementation "com.google.firebase:firebase-storage:16.0.2"

I’m new to mobile, react native, and expo, so I might be missing something fundamental. Any help is appreciated.

package.json is below.

Thanks.

{
“private”: true,
“scripts”: {
“start”: “node node_modules/react-native/local-cli/cli.js start”,
“test”: “jest”
},
“dependencies”: {
“expo”: “^35.0.1”,
“expo-config”: “^1.0.0”,
“moment”: “^2.24.0”,
“react”: “16.12.0”,
“react-native”: “0.59.8”,
“react-native-actionsheet”: “^2.4.2”,
“react-native-button”: “^2.4.0”,
“react-native-elements”: “^1.2.7”,
“react-native-fast-image”: “^7.0.2”,
“react-native-fbsdk”: “^1.1.1”,
“react-native-firebase”: “^5.5.6”,
“react-native-geocoding”: “^0.4.0”,
“react-native-gesture-handler”: “~1.3.0”,
“react-native-image-picker”: “^1.1.0”,
“react-native-maps”: “~0.26.1”,
“react-native-modal-selector”: “1.1.2”,
“react-native-snap-carousel”: “^3.8.4”,
“react-native-star-rating”: “^1.1.0”,
“react-native-vector-icons”: “^6.6.0”,
“react-navigation”: “^4.0.10”,
“react-navigation-redux-helpers”: “^4.0.1”,
“react-redux”: “^7.1.3”,
“redux”: “^4.0.4”,
“scheduler”: “^0.18.0”
},
“devDependencies”: {
“babel-jest”: “24.9.0”,
“jest”: “24.9.0”,
“metro-react-native-babel-preset”: “0.57.0”,
“react-test-renderer”: “16.12.0”
},
“jest”: {
“preset”: “react-native”
}
}

i fixed my case

charge → // import firebase from “react-native-firebase”;

to import * as firebase from “firebase”;

1 Like