Logs / Error guide / Minecraft
Minecraft: “UnsupportedClassVersionError … class file version”
What the message means
The server or a plugin was built for a newer Java version than the one running on your server. Java then stops while loading. The number “class file version” tells you which version is needed.
What it looks like in the log
container@pterodactyl~ java -Xms128M -Xmx4096M -jar server.jar nogui
Error: LinkageError occurred while loading main class io.papermc.paperclip.Main
java.lang.UnsupportedClassVersionError: io/papermc/paperclip/Main has been compiled by a more recent version of the Java Runtime (class file version 65.0), this version of the Java Runtime only recognizes class file versions up to 61.0
container@pterodactyl~ Server marked as offline...
Excerpt from an example log, marked the way the analysis marks it.
Common causes
- New Minecraft versions need new Java versions: Java 21 from 1.20.5, Java 17 from 1.18, Java 16 for 1.17, older versions mostly Java 8.
- You updated the server jar but didn't switch the Java version in the panel.
- A single plugin or mod is built for a newer Java than the rest.
- Conversely, very old Forge versions won't start with a Java that's too new – then the log usually shows a different error message.
How to fix it
- Read the number: class file version 65 = Java 21, 61 = Java 17, 60 = Java 16, 52 = Java 8. The analysis converts this for you.
- Switch the Java version in your server's startup settings (in the panel usually under “Startup” or “Docker image”).
- Restart the server and check that the message is gone.
- If it only affects one plugin, download the version of it that matches your Minecraft and Java version.