Installing JDK on Windows
- Java SE 6 Update 29
- Windows (XP/Vista/7) OS
Downloading Java Development Kit (JDK):
You can download latest version of JDK from this location
Click on the download link to go to the download page.
Download the JDK suitable for your system requirement (Windows x86 for 32bit windows or Windows x64 for 64bit windows) to a safe location on your machine.
Installing Java Development Kit (JDK):
Double click the downloaded JDK exe file. Click the “Next” button.
The “Custom Setup” window allows you to select which parts of the JDK you want to install. If you want to change the installation directory click on change and specify the location where jdk will be installed. It is recommended to stick with the default settings. Click the “Next” button.
JDK “installing” window appears. It will take a few minutes to install the program features of the JDK.
By installing JDK, JRE will also be installed. Select Java Runtime Environment (JRE) installation location.
When the “Complete” screen appears, click on the “Finish” button. Now you have successfully installed the Java Development Kit!
Configuring the installed JDK on Windows:
The installed JDK must be configured to the windows environment so that the Java compiler (javac) and runtime (java) becomes available for compiling and running the Java application from any location on Windows.
NOTE: If JDK is not configured on windows environment then to compile and run your Java applications you must place them in <JAVA_HOME>/bin/ folder.
For Windows Vista/7:
- Click on Start -> Right click Computer -> Select Properties
- Click on “Advanced system settings” from left side Tasks menu.
- Click on “Advanced” tab and click on “Environment Variables…”.
- Select Path variable from “System variables” and click on “Edit…” and go to the end of the “Variable Value” and place a semi-colon (;) and add “<Your JDK installation folder>\bin” path as shown below.
- Click OK -> OK -> OK. Now you have successfully configured JDK and ready to develop applications in Java.
- Now open Command prompt and type “javac -version” and it should show the version number which you installed.
|NOTE: For earlier Windows version:|
Right click “My Computer” -> Select “Properties” -> “Advanced” tab and click on “Environment Variables…”
javac is the primary Java compiler, included in the Java Development Kit (JDK).
Also type “java -version” which is Java runtime included in JDK. Sometimes you may want to restart the computer for the PATH settings to take effect.
Done! If you haven’t encountered any problems, then the installation and configuration is complete.