Minecraft Server Performance Optimization Guide

Reduce lag, improve TPS, and optimize your Minecraft Java server with the right software, JVM flags, view distance tuning, and anti-lag plugins.

A comprehensive guide to getting the best performance out of your Minecraft Java server. Follow these steps in order — the highest-impact changes are at the top.

Use the Right Server Software

SoftwarePerformancePluginsMods
VanillaPoor
SpigotGood
PaperBest
PurpurBest
PufferfishBest
ForgeModerate
NeoForgeModerate
FabricGood

Paper is recommended for nearly all servers. It includes hundreds of optimizations over Vanilla and Spigot at no functional cost. To switch, see Switch Version or Install Custom JAR.

Apply Aikar's JVM Flags

Java's default garbage collection settings are terrible for Minecraft. Aikar's Flags are a community-maintained set of JVM arguments tuned specifically for Minecraft's memory patterns. They dramatically reduce GC pauses and stuttering.

See JVM Flags Guide for the full flag set and how to apply them.

Reduce View & Simulation Distance

This is the biggest single performance lever on any Minecraft server. Lowering view distance from 12 to 8 can double your TPS.

In server.properties:

view-distance=8
simulation-distance=6
Player CountRecommended view-distanceRecommended simulation-distance
1–10108
10–2086
20–5064
50+4–64

See View Distance Guide for details.

Don't Over-Allocate RAM

More RAM is NOT always better. Over-allocation causes longer garbage collection pauses, which causes server lag.

Allocate only what you actually need:

PlayersRecommended RAM
1–102–4 GB
10–204–6 GB
20–506–10 GB
50+10+ GB

For modded servers, increase by 2–4 GB depending on mod count. See How Much RAM.

Pre-Generate Chunks

Chunk generation is the most CPU-intensive task on a Minecraft server. Pre-generating chunks before players arrive eliminates lag spikes when players explore new areas.

Install the Chunky plugin and run:

/chunky radius 5000
/chunky start

This generates all chunks within 5000 blocks of spawn. Run it overnight.

See Pre-Generate Chunks for the full guide.

Paper-Specific Optimizations

If you're running Paper, these settings squeeze out extra performance.

config/paper-world-defaults.yml:

chunks:
  max-auto-save-chunks-per-tick: 8
  prevent-moving-into-unloaded-chunks: true
spawn:
  keep-spawn-loaded: false
  keep-spawn-loaded-range: 0
entity-per-chunk-save-limit:
  experience_orb: 16
  arrow: 16
  snowball: 16
  ender_pearl: 16

config/paper-global.yml:

chunk-system:
  gen-parallelism: default
  worker-threads: -1

Spigot/Bukkit Optimizations

In spigot.yml:

world-settings:
  default:
    mob-spawn-range: 6
    entity-activation-range:
      animals: 16
      monsters: 24
      misc: 8
      water: 12
    merge-radius:
      exp: 6.0
      item: 4.0

These reduce mob simulation overhead and merge nearby items/XP orbs.

Anti-Lag Plugins

PluginPurpose
SparkProfiler — shows exactly what's causing lag (essential)
ClearLaggAuto-removes ground items and entities on schedule
FarmControlLimits mob farms to reduce entity counts
LimitPillagersCaps pillager outpost spawns

Monitor Lag with Spark

Install Spark and run:

/spark tps
/spark health
/spark profiler start

Wait a few minutes during normal gameplay, then:

/spark profiler stop

Spark generates a web report showing exactly what's eating your tick time. Common culprits:

  • Chunk loading → reduce view-distance
  • Entity tick → reduce mob caps or use FarmControl
  • Pathfinding → mob farms are spawning too many entities
  • GC pauses → apply Aikar's Flags or right-size RAM

Schedule Regular Restarts

Long-running servers accumulate memory fragmentation and minor leaks. Restart every 12–24 hours via Schedules in the panel.

See Server Restart Schedule.

Quick Wins Checklist

If you only have 15 minutes, do these in order:

  1. ✅ Switch to Paper (if not already)
  2. ✅ Apply Aikar's Flags
  3. ✅ Lower view-distance to 8 and simulation-distance to 6
  4. ✅ Match RAM to player count (don't over-allocate)
  5. ✅ Install Spark to monitor

Most servers see 2–3x TPS improvement from these 5 changes alone.

How is this guide?

40% Off — Limited TimeGet your Minecraft server todayInstant setup, DDoS protection, and 24/7 support included.
Get a Server

On this page