ZappyHosting

Why servers lag (RAM, CPU, view distance, entities) — and how to fix it

The usual causes of lag on a friend-group server, and what actually fixes each one.

"Lag" covers a few different problems. Figuring out which one you have is most of the fix.

Is it the server or the connection?

  • Everyone lags at once, blocks pop back, mobs freeze: that's the server.
  • One player lags and nobody else does: that's usually their connection or their PC.
  • Everyone has high ping all the time: that's distance. Our hardware is on the US East Coast. Check your ping before you buy.

Cause 1: out of RAM

Lag that gets worse the longer the server's up, long freezes, then a crash. Fix: more RAM, or less loaded at once. This is the one we built Zappy around. You get 4× the RAM at the same price.

Cause 2: CPU, one tick at a time

Minecraft does most of its world work on one main thread. If one tick takes too long, everything waits. The usual culprits:

  • Entities: huge mob farms, hundreds of item frames, armor stands, villagers
  • Redstone and hoppers: big contraptions running all the time
  • Exploring new terrain: generating chunks is expensive

Cause 3: view and simulation distance

View distance is how far players see. Simulation distance is how far away things keep running. Each step up means a lot more chunks. For a friend server, a view distance around 8–10 and a simulation distance around 6–8 are a sensible start. Change them in server.properties.

Fixes that work

  1. Cap entities: kill off item piles, trim farms, limit villager breeding.
  2. Pre-generate the world: a pregen plugin or mod (like Chunky) generates terrain ahead of time so exploring doesn't stall the server.
  3. Use Paper if you're on vanilla. It's tuned for performance.
  4. Profile it: the spark plugin/mod shows exactly what's eating your ticks.
  5. Restart now and then on long-running modded servers.

Valheim

Valheim lag usually comes from very large bases (lots of placed pieces in one area) and lots of dropped items. Tidy up, and spread big builds out.

Still stuck? Send us your spark report or describe what's happening on Discord. We'll look at it.