If your server lags because of too many entities, the fix is almost never a plugin that deletes everything on the ground every few minutes. Dropped items already despawn after five minutes (6000 ticks). Paper and Spigot let you merge them harder, despawn junk items faster, cap what a chunk saves, and stop arrows and orbs piling up - all without touching anything a player is about to pick up. Find which entity type is growing with /paper entity list, fix the farm or design that produces it, and keep ClearLag-style timers as a last resort for public servers where you cannot talk to every builder. Timed wipes hide the cause and delete players' belongings, which costs you more in trust than it saves in ticks.
This is the third of the entity-focused guides. Villagers and mob farms are in villager and mob farm lag; redstone and hoppers are in redstone lag and limits. Here we deal with the entities nobody built on purpose: items, experience, projectiles, and the leftovers of farms.
What counts as an entity, and which ones cost#
Anything in a Minecraft world that is not a block is an entity: players, mobs, dropped items, experience orbs, arrows, minecarts, boats, armour stands, item frames, falling sand, primed TNT, display entities. They do not all cost the same.
| Entity type | Ticks? | Typical cost | Usual source of excess |
|---|---|---|---|
| Dropped items | Yes | Low each, high in thousands | Farms without collection, deaths, mob drops |
| Experience orbs | Yes | Low each | Mob grinders, smelting, breeding |
| Arrows and tridents | Yes | Low | Skeleton farms, PvP, dispensers |
| Hostile and passive mobs | Yes, with AI | Medium to high | Farms, pens, spawners |
| Minecarts and boats | Yes | Medium | Abandoned rail systems, mob transport |
| Armour stands | Yes, by default | Low to medium | Decoration, hologram plugins |
| Item frames | Barely | Mostly a client cost | Storage walls, maps |
| Falling blocks and TNT | Yes | High while active | Sand farms, TNT machines |
Two things about this table matter. First, the cheap entities become expensive through numbers: one item is nothing, eight thousand items in a chunk under a broken farm is a server that freezes whenever someone walks nearby. Second, some entity costs are on the client and the network rather than the server tick. Item frames and armour stands in their thousands make players' frame rates drop and inflate chunk packets long before they show up in /mspt.
Find what is actually piling up#
Measure before you set anything.
/paper entity list/paper entity list minecraft:item/paper entity list minecraft:experience_orb/execute if entity @e[type=minecraft:item]/paper entity list with no type gives counts per entity type across loaded chunks; with a type it lists the chunks holding the most, with coordinates. That turns "the server has too many entities" into "there are 4,100 items in one chunk at x: -310, z: 2290", which is a farm with a broken collection system and an owner you can message.
Check at different times. Entity buildup is local and only exists in loaded chunks, so a count taken at 4 a.m. tells you nothing about a base that is loaded at 8 p.m. If you want to watch the trend, run the count at a fixed time each evening and note it - a simple log in your staff channel is enough.
Then confirm the cost with a profile. If spark shows entity ticking small next to chunk loading or a plugin, the entity count is a symptom of something else or simply not the problem. Reading a spark report shows you where to look.
Despawn and merge settings that do the work#
Most of the entity cleanup you need is already built into Paper and Spigot. It is just not tuned.
merge-radius: item: 2.5 exp: 3.0item-despawn-rate: 6000arrow-despawn-rate: 1200trident-despawn-rate: 1200Those are the defaults. What each one does, and what is worth changing:
merge-radius.itemcontrols how close identical dropped items must be to combine into one stacked entity. Raising it to3.5or4.0reduces item entity counts under farms noticeably. Items visibly snap together over a slightly larger distance, which nobody minds.merge-radius.expdoes the same for experience orbs. Modern versions also merge orbs of equal value natively, so raising this has less effect than it used to, but it still helps under grinders.item-despawn-rateis in ticks:6000is the vanilla five minutes. Lowering it globally is the blunt version of ClearLag, and it hits the player whose death pile is two blocks away. Use the per-item option below instead.arrow-despawn-rateandtrident-despawn-ratedefault to1200ticks (one minute) for projectiles stuck in blocks. Lowering arrows to300is harmless and cleans up skeleton farms and archery ranges. Leave tridents: a player who throws one wants it back.
Paper adds finer control in config/paper-world-defaults.yml:
entities: spawning: alt-item-despawn-rate: enabled: true items: cobblestone: 300 netherrack: 300 rotten_flesh: 600 bamboo: 600alt-item-despawn-rate is the right tool for junk. Cobblestone from a mining trip and netherrack from a tunnel despawn in fifteen seconds instead of five minutes; everything else keeps the vanilla timer, so a dropped diamond pickaxe is untouched. Choose the list from what actually appears in /paper entity list minecraft:item on your server rather than copying one - a farm server's junk is different from a mining server's.
Other Paper options worth knowing in the same file:
entities.spawning.non-player-arrow-despawn-rateandcreative-arrow-despawn-ratedespawn arrows from skeletons, dispensers and creative players faster. Both default todefault, meaning the Spigot value.entities.armor-stands.tick: truecontrols whether armour stands tick. Setting it tofalsesaves work on servers with thousands of decorative stands; it breaks armour stands that need physics or that a plugin moves, so test first.entities.armor-stands.do-collision-entity-lookups: truecan be set tofalseto stop stands checking for collisions, a small saving on decoration-heavy servers.entities.spawning.despawn-rangescontrols soft and hard despawn distances for mobs, which affects how quickly unneeded mobs disappear when players move away.
Keys move between Paper versions. Open the file your server generated and search for the key name rather than pasting a block from a guide, this one included.
Per-chunk save limits: protection against entity bombs#
Sometimes the problem is not the tick but the load. A chunk that accumulated ten thousand experience orbs or arrows while unloaded, or a chunk someone deliberately filled with entities, freezes the server every time it loads. Paper has a guard for this:
chunks: entity-per-chunk-save-limit: arrow: 100 experience_orb: 100 snowball: 50 ender_pearl: 20 fireball: 20 small_fireball: 20By default every entry is -1, meaning unlimited. With a limit set, the chunk only saves that many of the type; the rest are dropped when the chunk unloads. For projectiles and orbs this is entirely safe and closes a well-known way of crashing servers with entity-stuffed chunks.
Do not use it as a general cap on items or animals. It deletes the excess silently at save time, and a player who finds their cows gone or their chest-break pile missing has no way to know why. For items and animals, fix the source and set rules players can see.
Manual cleanup that does not hurt anyone#
There are moments when you need to remove entities now - a farm broke overnight and buried a chunk in items, or a griefer spawned hundreds of mobs. Vanilla selectors are precise enough to do it safely.
/kill @e[type=minecraft:item,distance=..64]/kill @e[type=minecraft:experience_orb]/kill @e[type=minecraft:arrow]/kill @e[type=minecraft:item,nbt={Item:{id:"minecraft:cobblestone"}}]/kill @e[type=minecraft:zombie,distance=..100]Run area-limited commands from the location in question - stand there in-game, or wrap them in /execute positioned <x> <y> <z> run ... from the console. The distance=..64 filter means within 64 blocks of where the command runs; from the console without a position it is measured from world spawn, which is rarely what you want. The NBT filter on items is version-sensitive (item NBT changed to components in 1.20.5) so test it on a single item first.
Tell players before you do it. A message in chat and a minute's wait costs nothing and avoids the one person whose death pile was in the radius. The /minecraft: prefix is worth using when plugins override /kill with their own version.
ClearLag and timed wipes#
ClearLag is the best-known entity removal plugin. It runs on a timer, broadcasts warnings, removes entity types you configure, and offers commands such as /lagg clear to remove entities immediately, /lagg check to count them and /lagg killmobs to remove mobs. It has existed for a long time and development has been intermittent, so check that the build you download supports your Minecraft version before relying on it.
What it does well:
- On a big public server where you cannot audit every farm, a timed wipe of ground items with a visible countdown puts a ceiling on the worst case.
- Its counting commands are a quick way to see totals.
What it does badly:
- It removes the symptom. The farm keeps producing; the plugin keeps deleting. The tick cost of producing the items is still there.
- It deletes belongings. Death piles, items dropped for a trade, a shulker box someone set down for a second. The countdown helps; it does not help the player who was in the bathroom.
- It encourages bad builds. If the ground is wiped every five minutes, nobody needs to build collection systems, so they do not.
- Features that sound helpful often are not. Anything advertised as freeing memory by calling the Java garbage collector does nothing useful on a modern JVM and can cause a pause. Memory and entity counts are different problems - see how much RAM a Minecraft server needs.
If you do use a timed wipe, restrict it to junk item types, exclude named items and anything in a list of valuables, keep the interval long (ten minutes or more) and the warnings clear. On a whitelisted friends server, do not use one at all; you can talk to the person whose farm is overflowing.
Stacking plugins (RoseStacker is a common one) take a different approach: they combine many mobs or items into one entity with a count. That reduces entity numbers dramatically and changes how farms and mob drops behave, so it is a gameplay decision as much as a performance one.
Fixing the source#
Every entity problem has a builder behind it. The fixes are rarely complicated.
- Collection under every farm. Water streams into a few hoppers, or a hopper line, feeding storage. A farm that drops onto the ground is not finished.
- Overflow handling. When storage fills, items back up and spill. Builders should add an overflow that either stops the farm or disposes of the excess with a lava or cactus trash can - a deliberate disposal is cheaper than a pile.
- Kill chambers that kill. A mob grinder that leaves mobs alive in a holding area is a pen of AI. Kill quickly, collect immediately.
- No unused transport. Abandoned minecart chains and boats with mobs in them keep ticking. Clear them out when a project ends.
- Decoration in moderation. A storage room with three hundred item frames is a client-side frame rate problem for everyone who walks in, even if the server does not mind.
Write these down as server rules, and tie them to the per-base limits in your villager and redstone rules. Rules, moderation and staff covers making them stick.
On RE:NODE you can run the counting commands and the safe /kill forms straight from the panel console, with output unfiltered, and watch the memory and CPU graphs settle afterwards. Take a backup from the panel before any bulk cleanup - it is one button, stored off the machine, and a mistyped selector is exactly what it is for. Backups that actually restore explains why it is worth testing one.
FAQ#
How long do dropped items last in Minecraft?
Five minutes, which is 6000 ticks, unless changed by item-despawn-rate in spigot.yml or by Paper's alt-item-despawn-rate for specific items. Items in unloaded chunks do not age, so a pile in a chunk nobody visits waits until someone does.
Is ClearLag bad for my server?
Not bad, but blunt. It reduces entity counts by deleting things, which hides the farm or design causing them and occasionally deletes something a player wanted. Tune Paper's merge and despawn settings first and use ClearLag only where you cannot fix sources one by one.
What is the safest way to remove all dropped items?
/kill @e[type=minecraft:item], ideally limited by distance and run after a warning. Never use /kill @e without a type filter, because it removes players, pets, villagers, item frames and armour stands as well.
Do item frames and armour stands cause lag?
Armour stands tick by default and cost a little each; Paper can turn that off. Item frames barely tick but cost the client and the network, so a room full of them hurts players' frame rates more than the server tick.
Why does my server freeze when someone goes near one base?
A chunk is loading with a huge number of entities, often items or orbs that accumulated under a farm. Check with /paper entity list while the player is there, then set entity-per-chunk-save-limit for projectiles and orbs and fix the farm's collection.




Comments
Completely anonymous: no account, no email, no cookie. We store the name you type, the text and the time - nothing else. Links are limited and markup is not rendered.