How to open a jar file

Updated: 02/27/2019 by Computer Hope
Java logo

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 need to download and install the Java Runtime Environment (if you do not have it already) from the link below.

Once downloaded, you can run any jar file by double clicking the file name. Keep in mind that this only works if the jar file to be opened is executable. If it's not executable, you can view files within it instead.


If double-clicking the jar file does not result in the file being run, it's likely not an executable file and cannot run in this manner. Read the next section on how to view the contents of the 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.)

  1. Right-click the file and select Open With.
  2. In the Open With window, click the Browse button to open the File Explorer window.
  3. You need to find the Java executable file (java.exe file) on your computer 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 either 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 software program you want to set as the default program to open the jar file.