Java is one of the most popular programming languages at the moment; And people using the Java Virtual Machine programming language recognize this error.
Two situations can caused “javac is not recognized in Windows”
Firstly, the Java Development Kit (JDK) is not installed on your computer.
Secondly, the Java Development Kit (JDK) is installed but your system does not know how to find the JDK bin folder.
How to fix javac is not recognized as an internal or external command
Check if Java Development Kit (JDK) is installed on your Windows operating system. If java is not installed on your computer, download it and then install it on your Windows operating system.
The 64-bit version of the Java Development Kit (JDK) has the default bin folder location “C:\Program Files\Java\jdk-VersionNumber\bin”.
Open the command prompt at the location where the Java bin folder is located.
cd C:\Program Files\Java\jdk-13.0.2\bin
To see the version of Java you are running on your Windows computer, type the command below, then press enter.
If you see the version of java installed on your Windows computer, then you need to make java executable files available in your Windows operating system.
How to set variable path in Windows 10
In the Windows 10 search bar, type advanced system settings, then click view advanced system settings.
In the system properties window, select Environment variables.
Select path and click edit to open the Edit environment variables window.
Now click on new and add the path to find the bin directory of your Java Development Kit (JDK) version.
Java-8 C:\Program Files\Java\jdk1.8.0_162\bin
Java-9 C:\Program Files\Java\jdk-9.0.4\bin
Java-10 C:\Program Files\Java\jdk-10.0.1\bin
Java-11 C:\Program Files\Java\jdk-11.0.2\bin
Java-12 C:\Program Files\Java\jdk-12.0.2\bin
Java-13 C:\Program Files\Java\jdk-13.0.2\bin
Click OK to close the edit environment variable window.
Next, click OK to close the Environment variables window.
Click OK to close the System Properties window.
How to set system environment variables 10 using control panel
In the Windows search bar, type Control Panel, then click Control Panel in the search result.
Choose view by large icons or small icons.
Click on System.
On the left side, select Advanced system settings.
Click on Environment Variables.
In the system variables, select path, then click Edit.
Click new and add the address to find the Java bin directory.
Check if javac is available in Windows
Open a new command prompt, type the command below, then press enter.
How to fix Java is not recognized as an internal or external command
What To Read Next
- How to create email templates in gmail
- How to fix VLC won’t open
- Make VirtualBox Full Screen Windows 10
- How to turn on Bluetooth on Windows 10
If you like the content of this post or if it has been useful to you, please consider sharing it on your social media and follow me on Facebook and Twitter for more exclusive content.