Forge Server Tools · every failure mode · guides
Wrong Java version — FATAL
The server (or a mod) was compiled for a newer Java than the one running it. Class file version 52=Java 8, 60=Java 16, 61=Java 17, 65=Java 21.
Minecraft 1.17-1.20.4 wants Java 17. 1.20.5+ and 1.21 want Java 21. 1.16 and older want Java 8. Point your start script at the right JDK explicitly rather than relying on whatever `java` resolves to on PATH -- that is usually the cause.
Search your crash report or latest.log for any of these:
UnsupportedClassVersionError ... class file version has been compiled by a more recent version of the Java Runtime java.lang.UnsupportedClassVersionError
The free edition of Forge Server Doctor detects this one. It is a single Python file with no dependencies — point it at the report and it names the cause and the mod jar:
python3 forge_doctor.py crash-reports/crash-....txt