# Failed to install the react-native app

**URL:** <https://discuss.gradle.org/t/failed-to-install-the-react-native-app/42036>\
**Category:** Help/Discuss\
**Created:** [January 25, 2022, 9:25pm UTC](https://discuss.gradle.org/t/failed-to-install-the-react-native-app/42036 "2022-01-25T21:25:30Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![yse92](https://avatars.discourse-cdn.com/v4/letter/y/45deac/32.png) [@yse92](https://discuss.gradle.org/u/yse92)\
**Post date:** [January 25, 2022, 9:25pm UTC](https://discuss.gradle.org/t/failed-to-install-the-react-native-app/42036/1 "2022-01-25T21:25:30Z")

</div>

Please, need your help.  
I have the following error while building the react-native project on adroid studio:  
FAILURE: Build failed with an exception.

- What went wrong:  
The supplied javaHome seems to be invalid. I cannot find the java executable. Tried location: C:\Program Files\Java\jdk-16.  
0.1\bin\java.exe

- Try:  
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --s  
can to get full insights.

- Get more help at [https://help.gradle.org](https://help.gradle.org)

error Failed to install the app. Make sure you have the Android development environment set up: [https://reactnative.dev/doc](https://reactnative.dev/doc)  
s/environment-setup.  
Error: Command failed: gradlew.bat app:installDebug -PreactNativeDevServerPort=8081

FAILURE: Build failed with an exception.

---

<div class="post-metadata">

**Author:** ![christianGen](https://avatars.discourse-cdn.com/v4/letter/c/e495f1/32.png) [@christianGen](https://discuss.gradle.org/u/christianGen)\
**Post date:** [January 26, 2022, 6:26am UTC](https://discuss.gradle.org/t/failed-to-install-the-react-native-app/42036/2 "2022-01-26T06:26:22Z")

</div>

This not a gradle problem, but an incorrect configuration of android studio:

> <https://stackoverflow.com/questions/29356796/intellij-gradle-plugin-the-supplied-javahome-seems-to-be-invalid>
