Failed to run JAVA even though path is set on Windows 8 Enterprise - Cordova Failed to run JAVA even though path is set on Windows 8 Enterprise - Cordova windows windows

Failed to run JAVA even though path is set on Windows 8 Enterprise - Cordova


After I ran into the same issue, the following steps seems to have fixed it:

  • PATH needs to contain the bin folder of the Java installation path C:\Program Files\Java\jdk1.8.0_05\bin make sure the bin is included
  • JAVA_HOME needs to be set to the root of that Java installation folder, in my case C:\Program Files\Java\jdk1.8.0_05


In my case, i had multiple java instalations, and whenever i tried to print "echo %java_home%" command on command prompt, it always used to return "%java_home%" as it is.

So i uninstalled all the java versions and then installed it again, and whoola, it worked.

Hope this helps someone.


There is one thing you can try is to set this variable JAVA_HOME to C:\Program Files\Java\jdk1.7.0_51\bin

Since you are using Windows, you can go to Control Panel to update it.

You were able to run java -version probably because it's included in the User's path.