Home›Java›Mods›Lag Protect
Lag Protect
ModsJava

Lag Protect

Java mod listed for Minecraft 1.21. Downloads from the MC Java Mods app on Android.

by produckzz · on CurseForge

⬇ Download on CurseForge

The author built this one for Minecraft 1.21.5 on Fabric. On other versions it may install and then do nothing.

Requires Fabric API

Lag Protect

A lightweight, server-side Fabric mod that protects players from taking damage during lag spikes. When a player's connection stops responding, damage to them is cancelled until they catch back up, so nobody dies to a frozen screen.

How it works

The server sends each player a tiny ping on a configurable interval (default every 30 ticks). If the response is overdue by more than a second and the player has also stopped sending movement packets, they are considered lagging and incoming damage is cancelled. Protection ends the moment the client catches up.

Gamerule

/gamerule lag_protect <ticks> -- interval between pings (default 30, range 0-200, 0 disables the mod).

Lower = lag is detected faster, but packets are sent more frequently.

Notes

Protection covers damage only. A player who stays lagged past the vanilla keepalive timeout is still disconnected as normal.

License

This mod is available under the MIT license.

Quick facts

Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.

File checked by MCModsHub

These come from our own check of the pack file, not from the source page.

Explore more