How to Setup JAVA_HOME in windows

by Virender
August 11, 2015

How to Setup JAVA_HOME in windows

When we working with software which dependent on JDK (Java Development Kit). It’s give a problem for environment variables JAVA_HOME in windows.


For fix this issue we have following steps

  • Install JDK (Java Development Kit)
  • Setup up “JAVA_HOME” in Environment Variables


Install JDK (Java Development Kit)

You need to first download JDK from following path

Go to this url –

1. Click on Java Icons or JDK Download Button.

2. Then you will see list of Java Development Kit.  You need to accept the license agreement. Then click on Windows x86 or Windows x64. JDK (Java Development Kit) available in two version x86 and x64 . You need download according to your windows platform architecture.


3. After download JDK. Click on executable file and install JDK. Default installation path of JDK –

“C:program filesJava[JDKVersion]”

You have option to change installation path of JDK.


5. Check that JDK installed

 Check path into your system “C:program filesJava[JDKVersion]”

[JDKVersion] – Its version of JDK


Setup up “JAVA_HOME” in Environment Variables

follow these steps to setup JAVA_HOME variable on your Windows system.

1 . Right click the My Computer icon on desktop and Select Properties option.

2 . Click on “Advanced system settings link”

3. Click on “Advanced” tab. then Click the “Environment Variables” button.

4. Under User Variables, click “New”.

5. Enter the variable name as “JAVA_HOME” and variable value as path of JDK like this “C:Program FilesJavajdk1.6.0_45”.  Then Click OK.

6. Scroll to the beginning of the Variable value and insert and check “JAVA_HOME” listed.

7. Check that “JAVA_HOME” setup successfully. Type “%JAVA_HOME%” on command prompt.

Note – If the changes do not take effect restart Windows.

8. “%JAVA_HOME%” will show you JDK root directory. That means “JAVA_HOME” setup successfully.




Notify of
Inline Feedbacks
View all comments

Related posts