![]() |
VOOZH | about |
As of Java Edition 26.1, the Minecraft Launcher is bundled with the Microsoft build of OpenJDK (Java SE 25). If need be, it is possible to change the used Java version in the profile options menu.
Java is the programming language in which Minecraft: Java Edition is written. Java applications require and run inside Java Virtual Machines (JVM), which are supported across many different platforms. Because of this, developers can write a Java application and any platform that supports JVM can run the same Java application in their environment (write once, run anywhere). Notably, this makes the game supported on Windows, macOS, and Linux systems.
In order to run Minecraft: Java Edition, you would need the JVM software. It is typically bundled in Java Development Kit (JDK) or Java Runtime Environment (JRE). Both can be used to run the game, but JDK contains software and tools designed to develop Java applications, while JRE only contains the necessary parts to run one (excluding the development software and tools of JDK). This makes JDK a bit bigger than JRE, so if you aren't planning to do Java development anytime soon, you shouldn't need JDK.
As always, you should only use the latest version of Java supported by the game, which is Java 25 (as of 26.1). If you use custom JVM from an OpenJDK build, you should notice that Minecraft Launcher only allow the custom JVM with the same primary Java version as the minimum required Java version to launch the game.[1]
The latest versions of Java contain important enhancements to help improve performance, stability and security of the Java applications that run on your machine. Installing the latest Java update ensures that Minecraft continues to run safely and efficiently.
As mentioned before, you can get JVM from Java Runtime Environment (JRE) or Java Development Kit (JDK). They are usually distributed by a third-party vendor as an OpenJDK build. OpenJDK is the official open source reference implementation of Java, meaning it contains the software and tools required to run Java applications, such as JVM. Unlike the name suggested, an OpenJDK build does not strictly provide JDK, depending on the vendor, they may provide JRE-only build of OpenJDK.
There are many third-party vendors that provide OpenJDK build which you can pick from:
You will see that Java is divided into long-term support (LTS) and short-term support (STS) versions:
These choices won't impact typical users, as the game will likely run fine with both versions, and you should just use the latest version that Minecraft currently support (see ยง What is Java?).
This part of the tutorial will show you how to get Java for specific operating systems and update them after installing. For simplicity, we will show you how to download Adoptium's OpenJDK build, Temurin.
Before we install Java, you need to verify if you have Java installed on your system:
java -version to check your Java's version. If a version number is reported, and does not match the recommended version for Minecraft (see ยง Why update?), you should update Java from the tutorial below.If you have older versions of Java installed before, you can remove it in your system's settings. Otherwise, you can install multiple Java or OpenJDK builds in your system, as recently installed Java will likely overwrite the previous version (in PATH variable, but for installation, they may exist coincide with each other).
You can install Java by downloading the installer from the vendors' website, e.g. Adoptium's OpenJDK Temurin or Microsoft build of OpenJDK. After downloading, you can run the installer and install Java normally.
Winget is the official Windows package manager for installing programs from Microsoft Store and the Winget repository. Its included in Windows 10 and Windows 11 by default.
You can install an OpenJDK build using Winget. You can choose either Temurin or Microsoft build of OpenJDK:
winget install EclipseAdoptium.Temurin.25.JRE for Adoptium Temurin 25 JRE-only.winget install Microsoft.OpenJDK.25 for Microsoft build of OpenJDK 25.If you have installed Java from the vendors' website and want to update it after a long time, you can download the newer installer file and update the software that way.
If you have installed Java from Winget, you can update Java by running:
winget upgrade <java-package>, where <java-package> is the name of OpenJDK you have installed before.If you don't have OpenJDK, it can be installed using Homebrew package manager for macOS. Homebrew is a widely-used package manager for installing and updating software on macOS, including OpenJDK.
Homebrew is not installed by default on macOS, so you need to install it by running:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"[8]Then you can install OpenJDK by running:
brew install --cask temurin@25 for Adoptium Temurin 25.Keep in mind starting from Temurin 21, older macOS versions than 10.11 might not be supported. You can still install other LTS versions, such as Java 17 and Java 11 from Temurin or other builds.
To update Java, you need to update Homebrew's package index and upgrade:
brew update && brew upgrade --cask temurin@25Linux system comes in many different flavors called distribution (distro). Each distribution has different ways and configurations of installing software and maintaining them, so it's recommended you visit and read their documentation of doing so. In general, Linux is more favorable to open source programs, so it is recommended you use open source programs where applicable, such as OpenJDK.
Upgrading a single software is usually not recommended on Linux systems, so if you want to update Java, you may want to do full package upgrade on your system.
OpenJDK can be installed and updated by using apt:
sudo apt update.sudo apt install openjdk-25-jdk for OpenJDK 25.sudo apt install openjdk-8-jdk for OpenJDK 8.Adding the -headless at the end of the package name will install headless Java and remove GUI components.
To update Java, it is recommended to run sudo apt update && sudo apt upgrade which will upgrade Java along other programs.
OpenJDK can be installed using dnf:
sudo dnf install java-25-openjdk for OpenJDK 25.sudo dnf install java-1.8.0-openjdk for OpenJDK 8.Adding the -headless at the end of the package name will install headless Java and remove GUI components.
To update Java, it is recommended to run sudo dnf upgrade which will upgrade Java along other programs.
OpenJDK can be installed by using zypper:
sudo zypper install java-25-openjdk for OpenJDK 25.sudo zypper install java-1_8_0-openjdk for OpenJDK 8.For server usage, it is recommended to use openSUSE Leap rather than rolling-release Tumbleweed for stability.
To update Java, you can run the following commands depending on openSUSE editions:
sudo zypper update for openSUSE Leap, andsudo zypper dup for openSUSE Tumbleweed.OpenJDK distributions are available on Arch Linux repository, and can be installed by using pacman:
pacman -S jre25-openjdk for OpenJDK 25.pacman -S jre8-openjdk for OpenJDK 8.Adding the -headless at the end of the package name will install headless Java and remove GUI components.
To update Java, it is recommended do a full update and upgrade of the packages in your system:
pacman -Syu to update Java along other packages.If you encounter issues, it is recommended that you refer to the official Arch Linux Wiki.
Run emerge --ask virtual/jdk which installs OpenJDK according to your profile.
To update Java or specific versions, please refer to Gentoo Wiki.
Check your distro's documentation. It should have information on how to install OpenJDK.
Alternatively, you can visit Java's website directly to download the Java package for Linux. Most distros work with this (either 32 or 64-bit), but not usually recommended as your distro's package manager is more stable.
OpenJDK can be installed in FreeBSD using pkg:[9]
pkg install openjdk25 for OpenJDK 25.pkg install openjdk8-jre for OpenJDK 8 JRE-only.Once you have installed OpenJDK, you may see OpenJDK requires fdescfs and procfs. In order to satistfy this requirements, you can run the following commands:
mount -t fdescfs fdesc /dev/fd for fdescfs mounted on /dev/fd.mount -t procfs proc /proc for procfs mounted on /proc.This changes are not permanent on the next system reboot. In order to make them permanent, you need to add these mountpoints to your /etc/fstab file. Open them with your text editor (such as nano or vi) and insert the following lines into /etc/fstab:
# device-spec mount-point fs-type options dump fdesc /dev/fd fdescfs rw 0 0 proc /proc procfs rw 0 0
Lastly, you will want to rehash to be sure that you can use your new Java binaries immediately, run rehash in the command line.
For installing OpenJDK using ports instead, please visit this website for more information. Packages from pkg are compiled binaries of the ports.[10]
Issues relating to "Java lang", "Java server", "GC", "Lwjgl", "JVM", or "Exception" are maintained on the bug tracker. Issues should be reported and viewed there.