Free tool · runs in your browser

How much RAM does a Minecraft server need?

Free Minecraft server RAM calculator for vanilla, Paper and modded Java servers: heap by players, plugins and view distance, the start command and VPS size.

Minecraft: Java Edition server memory

Server software

Plugin servers: one jar, plugins in the plugins folder.

Java heap (Xms and Xmx)
6 GBPaperMC's own minimum
Server memory
7.5 GBheap + 1.5 GB for the system and Java itself
Standard KVM (Intel)
Standard KVM 2: 8 GB, 4 vCores€9.99 a month in Amsterdam
Hi-CPU KVM (AMD EPYC)
Hi-CPU 4: 8 GB, 4 vCores€19.99 a month in Amsterdam, stronger single cores

Start command

java -Xms6G -Xmx6G -XX:+UseG1GC -XX:+ParallelRefProcEnabled -XX:MaxGCPauseMillis=200 \ -XX:+UnlockExperimentalVMOptions -XX:+DisableExplicitGC -XX:+AlwaysPreTouch -XX:G1NewSizePercent=30 \ -XX:G1MaxNewSizePercent=40 -XX:G1HeapRegionSize=8M -XX:G1ReservePercent=20 -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 -jar paper.jar --nogui

PaperMC's recommended flags with -Xms and -Xmx set to 6G; rename paper.jar to your server's jar.

An estimate, not a measurement: the floors are PaperMC’s and the Minecraft Wiki’s, the per player, per plugin and modpack figures are ours (the explainer below shows each one). Watch the real heap once players are on and adjust. Java Edition only: we found no published figure for Bedrock Dedicated Server to start from.

On this page

How much RAM, in short

A vanilla Java Edition server for a handful of friends runs in 2 to 4 GB of heap. A Paper, Spigot or Purpur server should get at least 6 GB, because that is the low end of what PaperMC recommends, and a modpack, by our own estimate, starts at 4 to 8 GB before the first player joins. On top of the heap, the machine needs about 1.5 GB for the operating system and for the memory Java uses outside the heap. The calculator adds that for you and names the smallest plan with room for both.

Example servers

Typical setups, worked out by the calculator above with view distance 10 unless the row says otherwise. The plan columns are the smallest Standard KVM and Hi-CPU KVM plan whose memory holds the heap plus the system share.

ServerHeapServer memoryStandard KVMHi-CPU KVM
Vanilla, 5 friends2.5 GB4 GBStandard KVM 1 (4 GB)Hi-CPU 2 (4 GB)
Vanilla, 20 players6 GB7.5 GBStandard KVM 2 (8 GB)Hi-CPU 4 (8 GB)
Paper, 10 players, 15 plugins6 GB7.5 GBStandard KVM 2 (8 GB)Hi-CPU 4 (8 GB)
Paper, 50 players, 40 plugins14 GB15.5 GBStandard KVM 4 (16 GB)Hi-CPU 6 (16 GB)
Paper, 100 players, 60 plugins, view distance 825 GB26.5 GBStandard KVM 6 (32 GB)Hi-CPU 9 (28 GB)
Light modpack, 5 players6 GB7.5 GBStandard KVM 2 (8 GB)Hi-CPU 4 (8 GB)
Heavy modpack, 10 players11.5 GB13 GBStandard KVM 4 (16 GB)Hi-CPU 6 (16 GB)

What the published figures say

Two sources give numbers, and they differ a lot. PaperMC, whose server software many public servers run, writes in its guide to JVM flags that it recommends at least 6 to 10 GB, no matter how few players, and that more memory stops helping above a certain point. The Minecraft Wiki’s requirements page for dedicated servers is far lower for vanilla on a headless Linux machine:

PlayersRAMThe wiki calls it
1 to 5512 MBminimum
5 to 101 GBacceptable
10 to 153 GBrecommended
15 to 205 GBgood
20 or more6 GBoptimal

The wiki adds that a growing world and a large view distance raise memory use, that advanced redstone and farm builds can more than double it, and that the operating system needs memory of its own on top. Windows, with a desktop running, needs more for the same players. The calculator meets the wiki’s 6 GB at 20 players for vanilla, with a floor of 2 GB of our own above the wiki’s 512 MB minimum, and keeps to PaperMC’s 6 GB floor for plugin servers.

How the estimate is worked out

  • Vanilla: 1 GB plus 0.25 GB per player, at least 2 GB.
  • Paper, Spigot, Purpur: 2 GB plus 0.2 GB per player and 50 MB per plugin, never below PaperMC’s 6 GB.
  • Modded: 4 GB for a light pack (up to about 50 mods), 6 GB for a medium pack (about 50 to 150 mods), 8 GB for a heavy pack (150 mods or more, kitchen-sink packs), plus 0.35 GB per player. Forge, NeoForge and Fabric publish no memory figure, so these bases are ours alone.
  • View distance: 4% more for every chunk above the default of 10. Loaded chunks grow with the square of the radius, so at large view distances treat the result as a lower bound.
  • Heavy world: 50% more for big builds, farms and redstone, the cautious side of the wiki’s “can more than double”.
  • Server memory: the heap, rounded up to half a gigabyte, plus 1.5 GB, the upper end of the 1,000 to 1,500 MB PaperMC says to leave free.

The per player and per plugin figures are our own rules of thumb. The Minecraft Wiki puts a player object alone at about 50 to 100 MB and notes that a server takes more per player in practice; nobody publishes a per plugin figure, and a single plugin with a big cache or a map renderer can outweigh twenty small ones. Treat the result as where to start, then watch the real numbers.

Setting Xms and Xmx

The heap is set when Java starts. -Xmx is the most the heap may grow to and -Xms what it starts with; PaperMC recommends setting both to the same value, so the memory is taken once and never resized while the server runs. For a vanilla server with a 4 GB heap:

Vanilla, 4 GB heap
java -Xms4G -Xmx4G -jar server.jar nogui

Many Paper servers start with the flags PaperMC publishes (known as Aikar’s flags), which tune the G1 garbage collector for short pauses. The calculator prints them with your heap filled in. A modded server on NeoForge, or on Forge for 1.17 and later, is started by the loader’s run.sh or run.bat, which reads the heap from user_jvm_args.txt in the same folder:

user_jvm_args.txt, 8 GB heap
# user_jvm_args.txt
-Xms8G
-Xmx8G

Which Java version

PaperMC’s table lists Java 25 for Minecraft 26.1 and later, Java 21 for 1.20 to 1.21.11, Java 17 for 1.17 to 1.19 and Java 11 for 1.12 to 1.16.4. A Java that is too old refuses to load the server jar at all. Our guide to installing Java covers OpenJDK on Ubuntu and Windows.

When more RAM does not help

Minecraft runs the world on one main thread: 20 ticks a second, each with 50 ms to finish. When ticks take longer, players see lag however much memory is free. The usual causes and what helps:

  • Too many chunks: lower view-distance and simulation-distance in server.properties; the first decides what players see, the second where mobs and redstone run.
  • New terrain: generating chunks while players explore is expensive; pre-generating the world before opening the server moves that work out of play time.
  • Entities and farms: hundreds of mobs or items in one place, and large redstone clocks, cost tick time on every tick.
  • A slow plugin or mod: a profiler such as spark shows which one uses the tick.

Because the main thread is single, a stronger core helps a busy server more than extra cores do. That is the reason the calculator also names a Hi-CPU plan: fewer, stronger AMD EPYC vCores, where Standard KVM gives more memory and cores for the same price.

Checking real memory use

On the server, free -h shows what the whole machine uses, and the Java process should sit a little above its heap. In game, the spark plugin’s /spark health reports memory use and tick times, and /spark gc shows garbage collection. A heap that climbs to the limit and stays there after collections needs more room; one that never passes half of it is larger than it needs to be. For running the server itself, see setting up a Minecraft server on a VPS and choosing between Paper, Purpur, Fabric and Forge. Whether the server answers from the internet once it runs, with its version and player count, is what the Minecraft server status checker shows.

Frequently asked

How much RAM does a Minecraft server need?

For a small vanilla Java Edition server, 2 to 4 GB of heap is enough: the Minecraft Wiki lists 512 MB for one to five players and 1 GB for five to ten on a headless Linux server, and 6 GB as optimal above 20. A Paper server is a different case: PaperMC recommends at least 6 to 10 GB, however few players there are. Mods raise it further, and a large or heavily built world can more than double what the same players need.

Should -Xms and -Xmx be the same?

Yes, for a dedicated server. PaperMC's recommended flags set both to the same value, so the Java heap is reserved once at start and never grows or shrinks while players are online. Set them to the heap you planned, not to the machine's whole memory.

How much RAM should I leave for the operating system?

About 1 to 1.5 GB. PaperMC's advice is to reduce Xmx and Xms by roughly 1000 to 1500 MB below what the machine has, because Java uses memory outside the heap and the operating system needs its own. On an 8 GB server that means a heap of about 6.5 GB, not 8.

Does more RAM make a Minecraft server faster?

Only up to the point where the heap is big enough. Beyond that, PaperMC notes, more memory does not mean better performance. Lag that does not go away with more RAM usually comes from the main thread: too many entities, redstone farms, a large view distance or a slow plugin, which a faster CPU core and a profiler such as spark address, not more memory.

Which Java version does a Minecraft server need?

It depends on the Minecraft version. PaperMC's table lists Java 25 for 26.1 and later, Java 21 for 1.20 to 1.21.11 (the Minecraft Wiki and the NeoForge documentation name Java 21 as required from 1.20.5), Java 17 for 1.17 to 1.19 and Java 11 for 1.12 to 1.16.4. A newer Java usually works for Paper and vanilla, but old Forge versions need the Java they were built for; an older Java refuses to start the server.

Is anything I enter sent to a server?

No. The calculator runs entirely in your browser; the numbers you pick are kept in the part of the page address after the #, so you can share the result, and browsers never send that part to the server.

More free tools

All tools