How to Install and Configure ClearLagg on Your Minecraft Server

Install ClearLagg to auto-clear ground items and entities on your Minecraft Java server, reducing entity lag and improving TPS.

ClearLagg is the most-installed entity-cleanup plugin for Minecraft. It periodically removes ground items (dropped items, XP orbs, projectiles), caps entity counts, and provides commands for emergency cleanup. Combined with mob-spawn limits and view-distance tuning, it's one of the highest-impact lag fixes for survival servers.

Note: The plugin is officially named ClearLagg (two g's). Some older guides spell it ClearLag.

Why ClearLagg Matters

Dropped items don't despawn for 5 minutes by default. On a busy server with mob farms, item sorters, or active mining, ground items pile up into the thousands within minutes — and every single one gets ticked every game tick.

Entity typeDefault tick costCommon volume
Dropped itemLow individually, deadly in bulkMob farms produce 100s/minute
XP orbSameSame
ArrowLowSkeleton spawners produce constantly
Falling blockMediumTNT explosions, sand farms

A single mob farm can drop TPS from 20 to 14 with just ground item accumulation. ClearLagg fixes this with one config.

Install ClearLagg

Download ClearLagg

Get the latest from SpigotMC. Compatible with Bukkit, Spigot, Paper, Purpur, and Folia.

Stop the server

In the XGamingServer Panel, open Console and stop your server.

Upload to plugins/

Click Files in the sidebar and upload ClearLagg.jar to plugins/.

Start the server

Start from Console. ClearLagg generates plugins/ClearLagg/config.yml on first run.

Verify it loaded

plugins

ClearLagg should appear in green. Test:

lagg check

Output shows current entity counts.

The defaults are reasonable, but here's a tuned setup for most survival servers. Edit plugins/ClearLagg/config.yml:

Auto-Clear Ground Items

auto-removal:
  enabled: true
  interval: 300                # 5 minutes between clears
  warning:
    enabled: true
    seconds-before: 60         # First warning at T-60s
    extra-warnings: [30, 10, 5, 3, 2, 1]
    message: "&6[ClearLagg] &eGround items will be removed in &c%seconds% &eseconds!"
  broadcast-message: "&6[ClearLagg] &eRemoved &c%amount% &eground items"

Entity Limits

limit:
  enabled: true
  per-chunk:
    item: 64
    arrow: 32
    experience_orb: 32
    item_frame: 16
    armor_stand: 16

This caps how many of each entity type can exist per chunk. Excess entities are auto-removed.

What to Clear

auto-removal:
  filter:
    item: true
    experience_orb: true
    arrow: true
    snowball: true
    egg: true
    splash_potion: true
    item_frame: false      # Don't clear item frames!
    armor_stand: false     # Don't clear armor stands!
    boat: false
    minecart: false

Critical: Always set item_frame: false and armor_stand: false. Players use these for builds and decorations — clearing them is destructive.

Item Merge

merge:
  enabled: true
  radius: 3.0
  merge-on-pickup: true

Merges nearby item stacks to reduce entity count without losing items.

Commands

CommandPermissionDescription
/lagg checkclearlagg.checkShow current entity counts per type
/lagg clearclearlagg.clearManually clear ground items now
/lagg area <radius>clearlagg.areaClear entities within radius
/lagg killmobsclearlagg.killmobsKill all hostile mobs
/lagg unloadchunksclearlagg.unloadUnload non-essential chunks
/lagg gcclearlagg.gcTrigger Java garbage collection
/lagg haltclearlagg.haltPause all entity spawning temporarily
/lagg reloadclearlagg.reloadReload config

Don't grant /lagg perms to regular players. Use it as an admin tool.

Tuning Tips

Server typeRecommended interval
Survival, ~10 players600 (10 min)
Survival, ~30 players300 (5 min)
Skyblock / island180 (3 min)
Anarchy / mob farms120 (2 min)
Build / creative1800 (30 min) — items are rare
Minigame lobby60 (1 min)

Lower interval = more frequent cleanup = better TPS but more "items vanishing" complaints. Find the balance for your community.

What ClearLagg Does NOT Do

MisconceptionReality
"ClearLagg fixes all lag"It only fixes entity lag — not redstone, chunk gen, plugin lag
"It clears player inventories"Never — only ground entities
"It clears chest contents"Never — only entities, never blocks
"It removes mob farms"No — but it removes the dropped items the farm produces
"It improves chunk generation"No — use Chunky for that

For chunk and tick lag, install Spark and read Optimize Server.

Combined Performance Stack

ClearLagg works best as part of a complete optimization setup:

  1. ClearLagg — auto-clear ground items
  2. FarmControl — cap mob farms
  3. Spark — find lag sources
  4. Chunky — pre-generate world
  5. Aikar's Flags — tune JVM
  6. Lower view-distance — reduce tick load

Common Issues

ProblemFix
Players complain "my items disappeared"Lower clear frequency or increase warning time
Item frames cleared by mistakeSet item_frame: false in filter
Armor stands disappearedSet armor_stand: false in filter
Entity limits too lowRaise per-chunk caps in limit: section
Plugin doesn't loadWrong server type — Bukkit/Spigot/Paper only
Lag continues after installClearLagg only fixes entity lag — profile with Spark
Vehicles clearedSet boat: false and minecart: false

Common Mistakes

MistakeFix
Clearing item frames or armor standsAlways exclude from filter
Setting interval too low (e.g., 30s)Players hate it — keep at 120+
Disabling warningsAlways warn — players need time to pick up items
Granting /lagg to all playersRestrict to admin
Expecting ClearLagg to solve TPS issues from plugins/redstoneUse Spark to find the real cause
Not using merge featureItem merging reduces entity count cheaply

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