How much RAM for a Minecraft server? Vanilla and modded
How much RAM a Minecraft server needs, vanilla or modded, by player count and pack size, with a simple lookup table and a quick way to work it out.
· 6 min readThe short answer
As a rule of thumb, a vanilla Minecraft server needs about 2 GB of RAM for 1 to 4 players and 4 GB for 5 to 10. A modded server needs more, so start at 4 GB for a small pack, 6 GB for a medium one and 8 GB for a large one, then add 2 GB for 5 to 10 players and 4 GB for more than 10.
You're picking a server plan, or setting up a server at home, and every guide gives a different number. That's partly because there's no single right answer. The number depends on two things: how big your pack is and how many people play at once. Here's a sensible place to start, and how to check it once your friends are online.
The lookup table
This is a rule of thumb, not a measurement. We didn't benchmark these numbers. We built them from the published figures listed under the table, and the steps between them are our own judgement.
| Server | 1 to 4 players | 5 to 10 players | More than 10 players |
|---|---|---|---|
| Vanilla (no mods) | 2 GB | 4 GB | 6 GB |
| Small modpack (under about 50 mods) | 4 GB | 6 GB | 8 GB |
| Medium modpack (about 50 to 150 mods) | 6 GB | 8 GB | 10 GB |
| Large modpack (150+ mods) | 8 GB | 10 GB | 12 GB or more |
Where the numbers come from:
- Vanilla: the Minecraft Wiki lists 1 GB for 1 to 4 players, 2 GB for 5 to 10 and 4 GB for more than 10. It says those figures assume a new world and default settings, so we start one step above them.
- Modded: the file NeoForge creates for server memory says "A good default for a modded server is 4GB". That's our small-pack number.
- Big packs: the All The Mods team asks for at least 6 GB for most of its packs, and its sample server setup uses a maximum of 8 GB.
If your pack's own server files or page give a memory number, use that instead. Pack authors know their pack, and they don't all agree: Enigmatica 10's server setup file sets a maximum of 5 GB.
A quick server RAM calculator
The table is three small steps, so you can work it out yourself:
- Start with your pack. Vanilla is 2 GB, small is 4 GB, medium is 6 GB and large is 8 GB.
- Add your players. Add 2 GB for 5 to 10 people at once, or 4 GB for more than 10.
- Renting a server? Add about 1.5 GB. Java needs memory beyond the amount you give the server, so a plan should be a bit bigger than the number you worked out. The next section explains why.
For example, a medium pack with 6 friends on a rented server is 6 + 2 + 1.5, or 9.5 GB. In practice that means a 10 GB plan.
Count the most people who'll be online at the same time, not everyone on your whitelist.
What "dedicated RAM" means
Dedicated RAM is the memory set aside for the server. On a server you run yourself, it's the -Xmx value: -Xmx6G gives the server up to 6 GB. For a NeoForge server, that line goes in user_jvm_args.txt, as our guide to making a modded server shows. On a rented server, look for a memory setting in the host's control panel.
The size of a plan and the -Xmx value aren't the same thing. Paper's documentation warns that Java needs extra memory on top of -Xmx, and advises going about 1000 to 1500 MB below what your host gives you. On an 8 GB plan, it suggests 6500 MB. Paper is a different kind of server, but the same warning applies to anything that runs on Java.
If the server runs on your own computer, leave room for everything else too. The Minecraft Wiki says Windows or a desktop Linux system needs at least 1 GB of its own. If you also play on that computer, the game needs its own allocation as well, so add the two together before you decide.
Why vanilla and modded are so different
A vanilla server only has to run Minecraft. A modded server also has to load every mod, plus all the blocks, items, recipes and machines they add, before anyone joins. That memory is in use even when the server is empty.
The mod count is only a rough guide. Big tech and world generation mods use far more than small tweaks, so a pack with fewer mods can still need more memory. Our guide to how much RAM a modpack needs explains why.
Why more players need more memory
The Minecraft Wiki says a player takes about 50 to 100 MB of memory on their own, but that the server often needs much more per player. The bigger cost is the world around them. Each player keeps a patch of the world loaded, so five friends exploring in five directions cost more than five friends sharing a base.
That patch is set by view-distance in server.properties. The default is 10, measured in chunks (16 by 16 block sections of the world) in every direction from the player. Lowering it means less world loaded for each player, so it's the setting to try if you're short on memory.
How to check you got it right
Start with the table, then watch the server while people are playing.
- Too little: the server crashes with
OutOfMemoryError. Look inlogs/latest.login the server folder. - See the real number: the free spark mod can run on the server alone. In-game or in the server console,
/spark healthreports memory, CPU, disk use and TPS (ticks per second, how fast the server is keeping up). - Still laggy with memory to spare: more RAM won't help. Paper's documentation says that past a certain point, extra memory gives diminishing returns.
If lag hits when people explore new land, the server is busy generating the world. A pre-generator like Chunky does that work once, before everyone joins.
Let the pack tell you the number
A table can only guess at your pack. Packspire builds NeoForge 1.21.1 packs and tests each one on a real server and a real game client, measuring memory as it goes, so the pack's page says how much a server needs and how much to set in your launcher.
Plan your pack with Packspire. Setting up from scratch? Start with how to make a modded Minecraft server.
Frequently asked questions
How much RAM do I need for a Minecraft server with 5 players?
As a rule of thumb, about 4 GB for vanilla, 6 GB for a small modpack, 8 GB for a medium one and 10 GB for a large one. If your pack gives its own number, use that.
How much dedicated RAM should a modded Minecraft server have?
Start at 4 GB for a small pack, 6 GB for a medium pack and 8 GB for a large pack, then add more for bigger groups. NeoForge's own suggested default for a modded server is 4 GB.
Is 4 GB enough for a Minecraft server?
For vanilla with a small group, yes. The Minecraft Wiki lists 4 GB even for more than 10 players. For modded, 4 GB suits a small pack and a few friends. Medium and large packs usually want more.
Is there a Minecraft server RAM calculator?
Calculators can only estimate, because the real number depends on your pack. The sum on this page works the same way: start with your pack size, add for players, and add about 1.5 GB if you're renting.
Can a Minecraft server have too much RAM?
It can have more than it can use. Paper's documentation says extra memory stops helping past a certain point, and that buying 32 GB for a server wastes money. Start with the table, then check real use with spark.
Sources
- Minecraft Wiki: Server/Requirements, for the vanilla RAM table, memory per player and the operating system's share
- NeoForge's default user_jvm_args.txt, for the 4 GB modded default and the
-Xmxsetting - AllTheGuides: server setup, the All The Mods team's guide, for its 6 GB minimum and sample 8 GB maximum
- Enigmatica 10's server setup file, for its 5 GB maximum
- Paper: Aikar's flags, for leaving room below your plan's memory and for diminishing returns
- Minecraft Wiki: server.properties, for
view-distance - spark: command usage, for
/spark health - NeoForge user guide: installing a server, for
user_jvm_args.txt
