Skip to content

Install

Godot-JVM needs a JDK to build your code and run it in the editor. See Compatibility and requirements for supported versions and platforms. The Godot-JVM addon itself comes with the project you create on the next page.

Install a JDK

Install JDK 17 or newer; Eclipse Temurin is recommended. The JDK includes the runtime and tools needed to build your code.

With Homebrew installed, run:

1
brew install --cask temurin@21

Install a JDK through your distribution's package manager, or use a Temurin build for your distribution.

Use an installer from Adoptium, or install with Chocolatey:

1
choco install temurin21

Verify the installation

Open a new terminal and run:

1
2
java -version
javac -version

Both commands must report version 17 or newer.

Java version output showing an installed JDK 17

If they do, the JDK is on your PATH. The editor can use it when neither an embedded JRE nor a usable JAVA_HOME takes priority.

If a command is not found, or reports an older version, your installer did not update PATH or another Java shadows the new one. Either fix PATH, or set JAVA_HOME to the JDK's installation directory. The editor checks JAVA_HOME before PATH.

Which JDK the editor uses

The editor looks for a JVM in this order: an explicit --jvm-path, the embedded JRE under jvm/, JAVA_HOME, the first usable java on PATH, then on macOS the JDK reported by /usr/libexec/java_home -v 17+. Exported games use the embedded JRE unless --jvm-path overrides it. An invalid explicit path fails startup without fallback.

macOS: make the JDK visible to the editor

On macOS, an editor opened from Finder or the Dock does not inherit your shell's environment, so a working terminal does not guarantee the editor finds the JDK. Set JAVA_HOME for graphical applications, replacing the path with your JDK's home directory:

1
launchctl setenv JAVA_HOME /path/to/jdk/Contents/Home