Search Knowledgebase

How to Change the Version of Java that Minecraft Uses

On the 3rd of October 2025 Minecraft clients running Java 7 started to fail to connect to the authentication servers. In the vanilla Minecraft Launcher this is all versions up to and including Minecraft 1.16.5.

One workaround is to change the version of Java that Minecraft uses - This guide will help you achieve that.

If you are playing on a modpack then you should be aware that updating to too high a version of Java may stop your modpack from starting. To be safe only update packs affected by this problem and only update to Java 8.

You may find that you need to update or change the version of Java that your Minecraft is using. The main reasons to do this are:

  • Bug fixes
  • Security fixes
  • Improved performance

Locations of versions of Java installed by the Minecraft launcher

Replace <USERNAME> with your Windows username.

  • Java 7 - C:\Program Files (x86)\Minecraft Launcher\runtime\jre-legacy\windows-x64\jre-legacy\bin\javaw.exe
  • Java 8 - C:\Users\<USERNAME>\AppData\Local\Packages\Microsoft.4297127D64EC6_8wekyb3d8bbwe\LocalCache\Local\runtime\jre-legacy\windows-x64\jre-legacy\bin\javaw.exe
  • Java 16 - C:\Program Files (x86)\Minecraft Launcher\runtime\java-runtime-alpha\windows-x64\java-runtime-alpha\bin\javaw.exe
  • Java 17 - C:\Users\<USERNAME>\AppData\Local\Packages\Microsoft.4297127D64EC6_8wekyb3d8bbwe\LocalCache\Local\runtime\java-runtime-gamma\windows-x64\java-runtime-gamma\bin\javaw.exe
  • Java 21 - C:\Users\<USERNAME>\AppData\Local\Packages\Microsoft.4297127D64EC6_8wekyb3d8bbwe\LocalCache\Local\runtime\java-runtime-delta\windows-x64\java-runtime-delta\bin\javaw.exe

Other installs of Java

You may also manually install Java and use that instead. Here are the most commonly used providers of Java:

They each install to different locations. Pay attention when running the installer and make a note of where the files are installed.

How to change the version of Java your Minecraft client uses in the Minecraft Launcher

  1. Open the Minecraft Launcher
  2. Click on Installations
  3. Find the installation for the version of Minecraft you want to play
  4. Hover over it and click the button with the three dots and select Edit
  5. Click More Options
  6. Next to the Java Executable box, click Browse
  7. Find the javaw.exe you want to use (see above), highlight it and click Open
  8. Click Save

How to change the version of Java your Minecraft client uses in the CurseForge App

Note: You cannot change the Java 7 version. If a modpack uses Java 7 then you will either have to manually change the Java version in the Minecraft Launcher each time you start the pack or install the modpack on a launcher that does allow you to change the Java version. ATLauncher and MultiMC allow you to install CurseForge packs and set which Java version to use.

CurseForge lets you select different installs for Java 8, Java 17, and Java 21. This allows you to run versions of Java that have bug and security fixes.

You could use this to make older versions of Minecraft to run using newer versions of Java than they were meant for but beware that this change affects all installed packs and may cause problems on some modpacks.

  1. Open CurseForge App
  2. Click the Settings (gear) icon in the bottom right
  3. Click Minecraft in the left hand menu
  4. Scroll down to Java Versions
  5. Click the Choose button next to the version of Java you want to replace
  6. Find the javaw.exe you want to use (see above), highlight it and click Open
  7. Click Save

How to change the version of Java your Minecraft client uses in the ATLauncher App

Note: CurseForge modpacks will be set to use whatever Java version that pack uses by default. Use the per instance method to override it.

Set the global default Java version

  1. Open ATLauncher
  2. Click Settings
  3. Click Java/Minecraft
  4. Next to Java Path either:
    1. Select a version from the drop-down
      or
    2. Click Browse and locate the javaw.exe for the version of Java you want to use (see above)
  5. Click Save

Set the Java version per instance

  1. Open ATLauncher
  2. Click Instances
  3. On the instance, Click Settings
  4. Click Java/Minecraft
  5. Make sure Use Java Provided By Minecraft is set to No
  6. Next to Java Path either:
    1. Select a version from the drop-down
      or
    2. Click Browse and locate the javaw.exe for the version of Java you want to use (see above) and click Open
  7. Click Save

How to change the version of Java your Minecraft client uses in the Modrinth App

Set the global default Java version

  1. Open Modrinth App
  2. Click Settings (gear) icon in the bottom left
  3. Click Java Installations
  4. Click the Browse button next to the version of Java you want to replace
  5. Locate the javaw.exe for the version of Java you want to use (see above)
  6. Click Open

Set the Java version per instance

  1. Open ATLauncher
  2. Click Library (books) icon
  3. Click the instance
  4. Click Instance settings (gear) icon at the top right
  5. Click Java and memory
  6. Tick the Custom Java installation box
  7. Click the Browse and locate the javaw.exe for the version of Java you want to use (see above)
  8. Click Open

How to change the version of Java your Minecraft client uses in the Technic Launcher

Note: Overriding the Java version affects all packs. You may find that some old packs will not work with much newer versions of Java

  1. Open Technic Launcher
  2. Click Launcher Options at the top-right
  3. Click Java Settings
  4. Untick Use Mojang Java runtimes
  5. Next to Minecraft Java Version either:
    1. Select a version from the drop-down
      or
    2. Click Another Version and locate the javaw.exe for the version of Java you want to use (see above) and click Open

How to change the version of Java your Minecraft client uses in the FTB App

FTB App allows you to set the Java version per instance.

  1. Open FTB App
  2. Click Library (book) icon
  3. Click on the instance
  4. Click Settings at the top right
  5. Scroll down to find Java Version
  6. Either:
    1. Click the current version and then select a version from the drop-down
      or
    2. Click Browse and locate the javaw.exe for the version of Java you want to use (see above) and click Open

How to change the version of Java your Minecraft client uses in MultiMC

Set the global default Java version

  1. Open MultiMC
  2. Click Settings
  3. Click Java in the left hand menu
  4. In the Java Runtime section click 3 dots
  5. Locate the javaw.exe for the version of Java you want to use (see above) and click Open

Set the Java version per instance

  1. Open MultiMC
  2. Click the instance
  3. Click Edit Instance in the right hand menu
  4. Click Settings in the left hand menu
  5. In the Java tab tick the Java installation box
  6. Click Browse...
  7. Locate the javaw.exe for the version of Java you want to use (see above) and click Open
  • 0 Users Found This Useful

Was this answer helpful?

 Print this Article

Also Read

Unable to Connect to Any Minecraft Server - java.net.SocketException: Address family not supported by protocol family: connect

Description When attempting to connect to any server the Minecraft client will time out. The...

Crashing on connecting due to holding a bugged item

This article relates to a client crash that is caused by holding a bugged item in the player's...

Diagnosing lag issues with a Timings report

If you are running a server with many plugins it can be very difficult to diagnose performance...

The Minecraft world has been reset on my server

If you've logged in to play on your Minecraft server and the world has reset there may be a...

Help! My Minecraft World Disappeared

If your Minecraft world is gone or the world has changed without you knowing why, this...