Get started

Loafmas Up to 80% off your first payment, with the code added to your order for you See the codes Codes for the Loafmas sale

Guides / Minecraft / Mods and modpacks

Which Java a modpack server needs

The panel picks the Java for the pack's Minecraft version and names it in the plan. Check it, change it, or answer the Unsupported Java Version window.

Updated , checked on Minecraft Java 26.3

The panel picks the Java for a modpack server, and the install plan says which. You can change it on Versions or Startup. The Java follows the pack’s Minecraft version. In the plans the panel printed, Minecraft 1.12.2 ran on Java 8, 1.18.2 on Java 17 and 1.21.1 on Java 21. If a server starts on a Java that is too old, a window called Unsupported Java Version opens. The window’s Update Docker Image picks the Java the error asked for.

1. Read the plan before you install

  1. Open Add-ons, then Modpacks.
  2. Search the pack, press Install, then Choose a version.
  3. In What will happen, find the line Installs Forge for Minecraft 1.12.2, on Java 8. The loader, version and Java change with the pack (1 in the first picture).
The install plan window: the line that names the loader, the Minecraft version and the Java the server will run on
  1. Loader, Minecraft and Java

The picture shows All the Mods 10 on a server named “Survival with friends”. The picture shows NeoForge and Java 21. Your pack’s plan has the same parts.

The panel asks its software catalogue which Java that Minecraft version needs. It then picks the Java that matches exactly among the ones the server can run on. If none is exact, it takes the lowest newer one. For Forge and NeoForge packs it never goes above Java 21 when the version itself needs 21 or less.

Nothing changes until you press Install. At the install, the panel switches the server to that Java for you. If the server has no Java that fits, the plan shows a red line, this server has no image with Java (number) to run it on, and Install stays off.

2. Check it afterwards

  1. Open Add-ons, then Versions (1 in the second picture). The line above the tabs reads like (software) (version) · Java 21.
  2. Below it, Runs on Java (number), the Java this version needs. means it is right (2 in the second picture).
  3. A mismatch reads Runs on (current), but this version needs Java (needed). It may not start, or may break later. Press the button that follows, written Use (label).
The Versions page of a server showing the software and version with its Java above the tabs, and the line saying it runs on the Java this version needs
  1. Versions
  2. The Java it runs on

This second picture shows a Purpur server, not a pack. A server with a pack shows the same lines for its loader. At the foot of the page, Want a whole modpack instead? links to Install a modpack.

The Startup page has the same choice under Docker Image. It says whether the image gives the Java your software needs. If the choice is locked, a custom image was set for the server: ask Loafhosts support.

3. When the pack’s author says another Java

The author’s advice is the author’s, so compare it with the plan:

  • Create: Above and Beyond (Minecraft 1.16.5): Java 8.
  • DawnCraft (1.18.2): the author says Java 18 or 17.
  • DeceasedCraft (1.20.1): Java 17. Its wiki adds that Java 22 will not work.
  • FTB StoneBlock 4 and FTB Skies 2 (1.21.1): Java 21.
  • Craftoria (1.21.1): Java 21 or Java 25.

If an author warns that a Java is too new for the pack, change the Java on Versions (the line Runs on (label), but this version needs Java (N) and its Use (label) button) or on Startup. Do not use the Unsupported Java Version window for that: it is for a Java that is too old.

Minecraft’s own rule is a minimum, “or newer”. Its wiki warns that older versions can be unstable on a much newer Java, especially versions that need Java 8. That is why the panel picks the Java the version was built for, not the newest.

4. The Unsupported Java Version window

If the server stops and its output holds UnsupportedClassVersionError, has been compiled by a more recent version of the Java Runtime or requires running the server with Java 21 or above, this window opens: This server is currently running an unsupported version of Java and cannot be started.

Press Update Docker Image. It picks the Java the error asked for and starts the server again if you may.

The Crashes page says the same in its own words: The server runs on the wrong Java version, with the Java number it needs. That number comes from the game files: a class version minus 44, so 52 is Java 8 and 69 is Java 25.

By hand

On a machine you run yourself, type java -version to see the Java in use. Install a Java that is new enough for the pack’s Minecraft version, or the one the pack’s author names in step 3, and start the server with it. A pack’s author often gives the exact line in the server files.

The Minecraft Wiki lists the minimum Java for each Minecraft version:

  • 1.12 to 1.16.5: Java 8 or newer.
  • 1.17: Java 16.
  • 1.18 to 1.20.4: Java 17.
  • 1.20.5 to 1.21.11: Java 21.
  • 26.1 and newer: Java 25.

If it does not work

  • The window opens again after the fix. Compare the Java in step 2 with the pack author’s advice in step 3. If they still disagree, ask Loafhosts support from the Support page in the panel.
  • The plan refuses the pack for its Java. Pick another version of the pack, or ask Loafhosts support.
  • The server runs out of memory, not Java. See fix out-of-memory errors.

The steps for the pack are in install a modpack. More on the game: Minecraft servers.

Sources: minecraft.wiki: Update Java, deceasedcraft.wiki.gg: Getting Started With a Server, github.com: Wiki, feed-the-beast.com: 130 ftb stoneblock 4, curseforge.com: Dawn craft, github.com: Craftoria

Minecraft server hostingAll Minecraft guides