How to open a jar file
To open a jar file in Windows, you must have the Java Runtime Environment installed. Alternatively, you can use decompression software, such as an unzip utility, to view the files in the jar archive.
To run the file (Java Runtime Environment)
To run the jar file, you must download and install the Java Runtime Environment (if you do not have it already) from the link below.
You must install the full Java Runtime Environment program for Windows. If you only have a Java plugin installed for your Internet browser, it is not adequate to run a jar file.
Once downloaded, you can run any jar file by double-clicking the file name. Realize this only works if the jar file is executable.
If you know the jar file is executable, and have the Java Runtime Environment installed, but it still won't run, try the following:
- Access the Windows system environment variables.
- In the Environment Variables window, select the Path variable in the System variables section, and click Edit.
- In the Edit environment variables window, check if the Java folder path to the java.exe file exists in the Path variable. The folder path should look similar to one of the examples below.
32-bit Java install
C:\Program Files (x86)\Java\jre-1.8\bin
64-bit Java install
C:\Program Files\Java\jre-1.8\bin
- If you do not see the Java folder path, add that folder path to the Path variable.
- Click OK on each open window, and then restart your computer.
Try double-clicking the jar file again. If that still does not run the file, it's likely not an executable jar file and cannot function in this manner. You can try manually selecting the Java program to run it by following the steps below. Alternatively, try viewing the contents of the jar file instead.
Manually choose program to run jar file
If the jar file opens using an archive program, such as WinRAR or 7-Zip, and you want Java to open it instead, follow the instructions below. (The jar file must contain executable Java code for these steps to work.)
- Right-click the file and select Open With.
- In the Open With window, click the Browse button to open the File Explorer window.
- You need to find the Java executable file (java.exe file) on your computer's hard drive. It is often located in the "Program Files\Java" or "Program Files (x86)\Java" folder, within a possible subfolder below the Java folder. Once you find the file, select it and click OK.
To view the file (decompression)
To view individual files in a non-executable jar file, you can obtain compression/decompression software that works with jar files. We recommend using 7-Zip or WinRAR.
Once you have installed this software, run the software, open the jar file, and extract the files contained in it. Once the files are extracted, you can view the individual files by double-clicking them. Many of those files are probably text files, but others may require additional software to view them.
If the jar file defaults to be opened with an archive program, such as WinRAR or 7-Zip, you can change the default program. To change the default program that opens jar files, right-click the jar file, select Open With, then Choose default program. In the Open With window, click the Browse button to open the File Explorer window. You need to find the executable file (.exe file) for the program you want to set as the default program to open the jar file.