Minecraft JVM arguments are the options the Minecraft Launcher hands to Java before the game starts. On Java Edition they sit in one text field on each installation. They set memory limits and the garbage collector. Mojang's support pages cover changing the memory value and the collector.
What the JVM arguments field is
Java Edition runs inside a Java Virtual Machine (JVM), and JVM arguments are the switches given to it at launch. The Minecraft Wiki says the launcher builds the full start command from the selected version's client.json, the options set in the launcher and the operating system. Since 1.12.2 the version file defines the arguments. Before that, the JVM arguments were defined directly in the launcher.
In the launcher you reach the field through Installations, then the installation, then More Options (Mojang Support, text last edited 7 January 2026). Our RAM allocation guide has the steps, so this page only explains what the text means.
What the default arguments do
Mojang's support pages point to a memory value written as -Xmx2G and a phrase, -XX:+UseZGC, that you replace when switching garbage collectors. The Minecraft Wiki lists the other JVM arguments the launcher can pass, and which ones you see depends on the version and operating system.
| Argument | What it does | Where it is stated |
|---|---|---|
| -Xmx | Sets the maximum memory used | Minecraft Wiki, Mojang Support |
| -Xms | Sets the initial memory used | Minecraft Wiki |
| -Xss | Sets the memory used for the stack | Minecraft Wiki |
| -XX:+UseZGC | The phrase Mojang tells you to replace when switching the garbage collector | Mojang Support |
| -XstartOnFirstThread | Starts the JVM on the first thread; some macOS versions need it, others hang with it | Minecraft Wiki |
| -XX:HeapDumpPath=MojangTricksIntelDriversForPerformance_javaw.exe_minecraft.exe.heapdump | Supposedly makes Intel drivers on dual-GPU laptops pick the dedicated GPU | Minecraft Wiki, citing a Reddit user |
What -Xmx and -Xms mean
-Xmx is the ceiling on memory the game may use. -Xms is the amount it starts with. Byte counts take the suffixes K, M or G, each worth 1024 of the previous unit, so -Xmx4G means 4 gigabytes.
Mojang says the default allocation changed from 2 GB to 4 GB after 26.1-snapshot-2. With under 4 GB of RAM you must set it back to 2 GB to avoid crashes. On a 64-bit system Mojang gives half of your RAM as the recommended maximum. How much the game actually needs is a separate question, covered in how much RAM Minecraft Java needs.
The garbage collector Mojang documents
Garbage collection is the Java memory clean-up that Mojang calls a tool for improving game performance. From 26.1-snapshot-1 the default collector changed. Mojang's page tells players with performance problems to swap -XX:+UseZGC for this set, which selects G1: -XX:+UnlockExperimentalVMOptions -XX:+UseG1GC -XX:G1NewSizePercent=20 -XX:G1ReservePercent=20 -XX:MaxGCPauseMillis=50 -XX:G1HeapRegionSize=32M.
Mojang does not say either collector is faster in general, and we ran no benchmark. It offers the swap only as a fallback.
Why copied flags rarely help and can break launch
The edits Mojang documents are the memory value and the collector. We found no Mojang or Minecraft Wiki statement that other flags improve the client, and we ran no benchmark. A flag can also do harm: the Minecraft Wiki says -XstartOnFirstThread is required on some macOS versions while others break with it, leaving the game stuck as not responding. Mojang's own advice is narrow: if the game fails to start after an edit, check the new text for syntax mistakes or case differences against your saved backup.
One more trap is Java itself. The Minecraft Wiki says the launcher accepts a custom JVM only when its main Java version matches the minimum the game requires, and lists Java 25 for 26.1 and later. Check which Java each release needs before pointing an installation at another runtime.
How this differs from server start flags
A server has no launcher field. Its flags are typed into the command that starts it, such as java -jar server.jar --nogui in the Minecraft Wiki's setup tutorial. PaperMC's Aikar's flags are one such set: a long G1 list that starts with -Xms10G -Xmx10G and ends in -jar paper.jar --nogui. PaperMC suggests at least 6 to 10 GB for a server and says to keep -Xms equal to -Xmx. The set is covered on our Aikar's flags page.
This page rests on Mojang Support pages edited 7 January 2026, the Minecraft Wiki and PaperMC docs, all read on 5 November 2026. We changed no launcher settings and ran no tests.
Sources
- 1.Fix Minecraft Java Edition game crashes by checking memory allocation (help.minecraft.net, text last edited 7 January 2026)
- 2.Change the garbage collector for Minecraft Java Edition (help.minecraft.net, text last edited 7 January 2026)
- 3.Java Edition client command line arguments (minecraft.wiki)
- 4.Tutorial on setting up a Java Edition server (minecraft.wiki)
- 5.Aikar's flags (docs.papermc.io, PaperMC)




