Troubleshooting Server Lag

7 min read Updated Apr 2, 2026

This guide will help you identify and fix lag issues on your Minecraft server, including understanding performance metrics, generating diagnostic reports, and applying common fixes.

Contents

Understanding Lag

Diagnosing the Problem

Fixing Lag

Note: All commands in this guide can be run from the Game Panel console. When using the console, omit the / prefix (e.g., use tps instead of /tps).


What is TPS?

TPS stands for Ticks Per Second. Minecraft servers run on a tick-based system where the server processes all game logic 20 times per second. Each "tick" handles player movement, mob AI, block updates, redstone, and more.

TPS Scale

TPS Performance Experience
20 Perfect Smooth gameplay, no lag
18-19 Good Minor delays, barely noticeable
15-17 Moderate Noticeable lag, delayed actions
10-14 Poor Significant lag, frustrating gameplay
Below 10 Severe Unplayable, major delays

Checking Your TPS

Built-in command (requires operator in-game):

/tps

This will display the TPS for the last 1 minute, 5 minutes, and 15 minutes.

Using Spark (recommended):

/spark tps

What Causes Low TPS?

When the server cannot complete all its tasks within 50ms (1/20th of a second), TPS drops. The server falls behind and players experience lag.

Common Causes of Lag

Too Many Entities

Entities include mobs, animals, item drops, minecarts, and armour stands. Each entity requires processing power every tick.

Signs:

  • Lag near farms or mob grinders
  • Thousands of animals in one area
  • Item drops not being picked up or despawning

Plugin Issues

Poorly coded or resource-heavy plugins can consume excessive server resources.

Signs:

  • Lag started after installing a new plugin
  • Lag spikes at regular intervals (scheduled tasks)
  • High CPU usage shown in Game Panel

Large or Unoptimised Worlds

Large worlds with many loaded chunks require more memory and processing power.

Signs:

  • Lag when exploring new areas
  • Server struggles when players spread out
  • High memory usage shown in Game Panel

Insufficient RAM

If your server does not have enough memory, it will struggle to keep up with demands.

Signs:

  • Consistent lag regardless of player count
  • Memory usage near 100% in Game Panel
  • Server crashes with "Out of Memory" errors

Redstone and Hopper Systems

Complex redstone contraptions and large hopper systems can cause significant lag.

Signs:

  • Lag near specific builds
  • TPS drops when redstone activates
  • Chunk-specific performance issues

Using Spark

Spark is a performance profiler that helps identify exactly what is causing lag on your server.

Installing Spark

  1. Download Spark from spark.lucko.me
  2. Choose the correct version for your server type (Paper, Spigot, etc.)
  3. Upload the JAR file to your plugins folder using the File Manager
  4. Restart your server

Running a Spark Report

To profile your server:

  1. Run the command:
    /spark profiler start
  2. Let it run for 2-5 minutes while the server is experiencing lag
  3. Stop the profiler:
    /spark profiler stop
  4. Spark will generate a link to your report

Quick health check:

/spark health

This shows current TPS, CPU usage, and memory status.

Understanding Spark Results

When you open your Spark report, you will see a breakdown of what is consuming server resources.

Key things to look for:

  • Tick percentage - What percentage of each tick is being used
  • Hot methods - Code that is running frequently and consuming resources
  • Plugin names - Identify which plugins appear most in the report

Common culprits:

  • Entity ticking (too many mobs)
  • Plugin event handlers (inefficient plugins)
  • Chunk loading/generation (world size issues)
  • Scheduled tasks (plugin timers)

Using Paper Timings

If you are running Paper (or a Paper fork), you can use the built-in timings system.

Generating a Timings Report

  1. Run the command:
    /timings on
  2. Wait 5-10 minutes during normal server activity
  3. Generate the report:
    /timings paste
  4. Click the link provided to view your report

Understanding Timings Results

The timings report shows how long each task takes to complete.

Key sections:

  • Plugins - Time spent by each plugin
  • Entities - Time spent processing entities
  • Chunks - Time spent on chunk operations
  • Scheduled Tasks - Repeating tasks and their impact

Look for:

  • Plugins using more than 10% of tick time
  • Entity counts that seem unusually high
  • Tasks that run very frequently

Reading and Interpreting Reports

What to Look For

In Spark:

  1. Open the report and look at the flame graph
  2. Larger sections = more resource usage
  3. Click on sections to drill down into specifics
  4. Look for plugin names or repeated patterns

In Timings:

  1. Check the "Plugins" section first
  2. Sort by total time or percentage
  3. Look for anything above 5-10% of tick time
  4. Check entity counts in the summary

Identifying the Problem

Report Shows Likely Cause Solution
High entity tick time Too many mobs/animals Reduce entity limits
Plugin using high % Inefficient plugin Remove or replace plugin
Chunk generation high World exploration Pregenerate chunks
Hopper/redstone tick high Complex contraptions Limit or redesign builds
Memory constantly full Insufficient RAM Upgrade or optimise

Quick Fixes

Reducing View Distance

View distance controls how many chunks are loaded around each player. Lowering this reduces server load significantly.

  1. Open server.properties in the File Manager
  2. Find view-distance=10 (default)
  3. Change to a lower value (6-8 is recommended for most servers)
  4. Save and restart your server

Also in spigot.yml:

view-distance: default

Change default to a number if you want to override the server.properties value.

Entity Limiting

Limit the number of entities that can exist in your world.

In bukkit.yml:

spawn-limits:
  monsters: 50
  animals: 10
  water-animals: 5
  water-ambient: 10
  ambient: 5

In paper.yml or paper-world-defaults.yml:

despawn-ranges:
  monster:
    soft: 28
    hard: 96
  creature:
    soft: 28
    hard: 96

Lower soft/hard ranges mean entities despawn closer to players.

Pregenerating World Chunks

Generating new chunks causes lag spikes. Pregenerating your world eliminates this.

Using Chunky plugin:

  1. Install Chunky from modrinth.com/plugin/chunky
  2. Set your world border:
    /worldborder set 10000
  3. Start pregeneration:
    /chunky start
  4. Let it run (can take hours for large worlds)

Tip: Run pregeneration when the server is empty or during low-activity hours.

Removing Problematic Plugins

If your report identifies a specific plugin causing issues:

  1. Check for plugin updates (newer versions may be optimised)
  2. Look for alternative plugins that do the same thing
  3. If no alternative exists, consider if the plugin is essential
  4. Remove the plugin JAR from your plugins folder
  5. Restart your server

Before removing:

  • Backup your server
  • Check if other plugins depend on it

Optimising Server Configuration

Quick wins in server.properties:

view-distance=8
simulation-distance=6
max-players=20

In spigot.yml:

mob-spawn-range: 6
entity-activation-range:
  animals: 16
  monsters: 24
  raiders: 48
  misc: 8
  water: 8
  villagers: 16
  flying-monsters: 48

In paper.yml:

max-auto-save-chunks-per-tick: 8
optimize-explosions: true

When to Upgrade RAM vs Optimise

Optimise First When:

  • Memory usage is below 80%
  • TPS drops are caused by specific activities (not constant)
  • Spark/Timings shows a specific plugin or feature causing issues
  • You have not tried reducing view distance or entity limits
  • Server runs fine with fewer players

Upgrade RAM When:

  • Memory usage is consistently above 90%
  • You have already optimised settings and plugins
  • Server crashes with "Out of Memory" errors
  • You need to support more players
  • You are running large modpacks that require more RAM

RAM Guidelines

Players Vanilla/Paper With Plugins Modded
1-5 2GB 3GB 4GB+
5-15 3GB 4GB 6GB+
15-30 4GB 6GB 8GB+
30+ 6GB+ 8GB+ 10GB+

Note: These are guidelines. Actual requirements depend on your specific plugins, mods, and world size.

Using the RAM Monitor

The Game Panel includes a RAM Monitor feature that helps you track memory usage and alerts you when your server is running low on memory.

  1. Go to Automation > RAM Monitor in the Game Panel
  2. Enable monitoring and set a threshold (e.g., 85%)
  3. Add your email address for notifications
  4. You will receive alerts when RAM usage exceeds your threshold

This helps you identify if you need to optimise or upgrade before players experience lag.

See Using the RAM Monitor for detailed instructions.

How to Upgrade

If you need more RAM for your server, you can upgrade your plan through the Billing System.


Need Help?

If you are still experiencing lag after trying these fixes, our support team can help analyse your server:

When contacting support, if possible please include:

  • A Spark or Timings report link
  • Description of when the lag occurs
  • Number of players online when lag happens
  • Any recent changes to your server

Was this article helpful?

Related Articles