Server Startup Flags Generator
Generate an optimized JVM start command and script for Paper, Purpur, Velocity, and Waterfall.
Software
Environment
Memory
4GBFlags
The community standard for Paper servers. Balanced G1GC tuning that suits almost everyone.
Jar file name
Advanced options
Start script
#!/usr/bin/env bash
java -Xms4096M -Xmx4096M -XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+DisableExplicitGC -XX:+AlwaysPreTouch -XX:G1HeapWastePercent=5 -XX:G1MixedGCCountTarget=4 -XX:InitiatingHeapOccupancyPercent=15 -XX:G1MixedGCLiveThresholdPercent=90 -XX:G1RSetUpdatingPauseTimePercent=5 -XX:SurvivorRatio=32 -XX:+PerfDisableSharedMem -XX:MaxTenuringThreshold=1 -Dusing.aikars.flags=https://mcflags.emc.gs -Daikars.new.flags=true -XX:G1NewSizePercent=30 -XX:G1MaxNewSizePercent=40 -XX:G1HeapRegionSize=8M -XX:G1ReservePercent=20 -jar server.jar --noguiFlags only
Just the JVM flags, for pasting into a host panel's startup field.
-XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:MaxGCPauseMillis=200 -XX:+UnlockExperimentalVMOptions -XX:+DisableExplicitGC -XX:+AlwaysPreTouch -XX:G1HeapWastePercent=5 -XX:G1MixedGCCountTarget=4 -XX:InitiatingHeapOccupancyPercent=15 -XX:G1MixedGCLiveThresholdPercent=90 -XX:G1RSetUpdatingPauseTimePercent=5 -XX:SurvivorRatio=32 -XX:+PerfDisableSharedMem -XX:MaxTenuringThreshold=1 -Dusing.aikars.flags=https://mcflags.emc.gs -Daikars.new.flags=true -XX:G1NewSizePercent=30 -XX:G1MaxNewSizePercent=40 -XX:G1HeapRegionSize=8M -XX:G1ReservePercent=20Why these flags?
- Xms is pinned to Xmx so the JVM grabs its full heap up front, avoiding mid-game resizes that cause lag spikes.
- Aikar's Flags are the trusted default: G1GC tuned to keep garbage-collection pauses short and predictable.
- At 12 GB or more, the G1GC presets switch to large-heap tuning (bigger regions, earlier collection) so big servers stay smooth.
- Most servers should pick Aikar's Flags and a sensible RAM size first. The other presets are for owners who benchmark their own hardware.
These flags are a starting point, not a substitute for right-sizing RAM. Verify against each author's current reference before relying on them in production.
How to generate Minecraft server startup flags
Startup flags are Java settings that control how your server uses memory. This tool builds a start command and script for Paper, Purpur, Velocity, and Waterfall, with Aikar's Flags picked by default for Paper and Purpur. It is for owners who run a server on their own machine or on a hosting panel.
- Pick the Software (Paper, Purpur, Velocity, or Waterfall), then pick the Environment it runs on, such as Linux (bash) or Pterodactyl panel.
- Set the Memory with the slider or the 2G to 32G buttons.
- Pick a set under Flags (default: Aikar's Flags for Paper and Purpur, Proxy for Velocity and Waterfall), then fill in the Jar file name if needed.
- Click Copy, or click Download to save the start script (start.sh, start.bat, or start.command). For a hosting panel, open Flags only and copy just the flags.
Common questions
What are Aikar's Flags?
Aikar's Flags are a set of Java flags for G1GC, tuned to keep garbage collection pauses short and steady. They are the common choice for Paper and its forks, such as Purpur. For 12 GB of memory or more, some values are adjusted.
How much RAM should I give my Minecraft server?
There is no fixed number, since it depends on your player count, plugins, and world size. Do not give all of the machine's RAM to Java. Leave room for Java itself and the system so the server is not killed for running out of memory; on a Pterodactyl panel, this tool leaves 15% free automatically.
Do Velocity and Waterfall use Aikar's Flags?
No. A proxy does not run worlds, so it needs different tuning. For Velocity and Waterfall, this tool uses the Proxy set, a light G1GC tuning.