How to Run .jar Files on Windows 10 : Solution
Unable To Run .JAR Files in Windows 10? A .jar file is based on a Java archive file format that may include a Java program inside it. Although you can apply a zip file extracting software like the 7zip to extract the .JAR files, it won’t enable you to run a complete Java app based on .JAR.
If you encounter a problem while opening a .jar file, you can examine the following methods.
Method 1: By Downloading Java
- Step 1: Proceed to Google.com and search for Java download. Click at the 1st result.
- Step 2: On the website download page, tick on the Download button in red to download the Java setup file.
- Step 3: Once the setup is finished, proceed to the location where the .jar file is saved and double-click on running the file.
- If it doesn’t open up, take the 2nd method.
Method 2: Through Properties
- Step 1: Right-click on it and choose Properties from the context menu.
- Step 2: In the Properties window, tick on Change.
- Step 3: In the following window, tap on More apps.
- Step 4: Scroll down and tap on Look for another app on this PC.
- Step 5: It gets you to the File Explorer, click on the C drive shortcut and observe the following path step by step:
- Double-tap on Program Files (x86)
- Double-tap on Java
- Double-tap on jre1.8.0_251
- Double-tap on bin
- Select javaw
- Step 6: As you double-tap on javaw, it takes you back to the Properties window. Tap on Apply and then press OK. If it doesn’t launch, try the 3rd method.
Method 3: Using Command Prompt
- Step 1: Tap on the Start on the desktop and type Command Prompt in the search box. Right-tap on the outcome and select Run as administrator.
- Step 2: In the Command Prompt window, type the below command in the below format and hit Enter:
- Command Prompt Admin Execute Command Enter
- The path listed is the same path for javaw as described in Method 2.
- This should resolve your problem, and you can open the .jar file.
- Although, if the problem persists, you can try the 4th method.
Method 4: Generating a .bat File
- Step 1: Launch notepad and type the following text on it:
- java -jar sample.jar
- Notepad Type Text
- Substitute the highlighted portion with whatever is the name of the .jar file.
- Step 2: Secure the file with any name that permits you, in the same location where your .jar file is stored, followed by .bat extension.
- For instance, we named the file as run.bat and changed the Save as the type to All Files.
- Press the Save button.
- Save As the Same Location As
- .jar File File Name With .bat All Files Save
- Now, double-tap on the run.bat file and your .jar file will open smoothly.
If all of the above systems fail, search for jarfix program on Google and download it. This will immediately fix the issue.