Minecraft anticheat guide
Diagnose Anticheat Lag With spark and Tick Timings
Find out whether an anticheat causes server lag using TPS, MSPT, ping, packet load, a spark profile, and an on-and-off comparison on staging.
Decide whether the anticheat is the cause
Compare tick time and a profiler capture with the anticheat enabled and disabled, under the same player load. If tick time rises only when the anticheat runs, it is a candidate cause. If the profile shows heavy work outside the anticheat, the anticheat is probably not the main problem.
A lag report alone cannot separate the anticheat from entities, chunk loading, other plugins, or network load. Measure before you change the anticheat settings.
Separate TPS, tick time, and ping
These three numbers answer different questions. Mixing them up leads to the wrong fix. TPS is a summary of server speed. Tick time (MSPT) is the time the server spends on each tick, and it shows load more directly. Ping describes the player's connection, which the server cannot fix by tuning checks.
| Measurement | Shows | Does not show |
|---|---|---|
| TPS | Whether the server is keeping up with its tick target | Which code or plugin used the time |
| Tick time (MSPT) | Average and worst time per tick, which reveals spikes | Whether the cost is in the anticheat or elsewhere |
| Player ping | Connection delay for each player | Server-side processing cost |
| Packet load | How many packets a client or group sends per second | Whether those packets are legitimate |
Record a baseline before testing
Capture numbers under a known load before you change anything. A short baseline taken at a random time often misleads, so use the same window and player count for each test.
Keep the baseline in the same notes file as your staging results so you can compare runs later.
Profile the server with spark
spark is a profiler for Minecraft servers. Use it to capture where tick time goes during a spike or a steady load. Run a bounded capture rather than leaving the profiler on. Check the help output of your installed spark version for the exact flags, because command syntax changes between releases.
spark tps
spark profiler --timeout 300
# after the capture finishes, open the report link printed in the consoleRead the profile by owner, not by guesses
In the report, look for the largest share of tick time, then identify which plugin owns each busy call path. Compare the anticheat's share with its share in the baseline capture. A large share during a bad moment can also come from a packet flood or from bot traffic, so check the player and packet context around that time before you blame the check code.
Compare with the anticheat disabled
Use the same load script on staging. Run once with the anticheat enabled, then again with its checks disabled or unloaded. Keep everything else the same. If tick time returns to normal only when the anticheat is off, you have a reproducible result to take to the anticheat's maintainers or your admin team.
Do not disable production checks to test. Use staging for this comparison. Repeat each run at least twice, so a single noisy window does not decide the result.
Use a decision table for the next step
Use the observed pattern to choose the next action. Each row is a starting point for investigation, not proof of cause.
| Observed pattern | Likely area | Next step |
|---|---|---|
| Tick time rises only with the anticheat enabled on staging | Anticheat work on the tick or packet path | Capture a profile, then review the anticheat's configuration and open an issue with the report |
| Spikes match a burst of packets from few players | Packet load or abuse | Check those accounts and rate limits for abuse, then retest |
| Tick time is high with the anticheat off too | Other plugins, entities, or chunks | Profile without the anticheat and review the largest owners |
| Ping is high for some players only | Player connection | Do not tune checks for this; review network path and proxy setup |
What we have not verified
This method does not provide expected tick times, overhead numbers, or product comparisons. Results depend on hardware, Java version, player behavior, and the other plugins on your server. Treat your own staging comparison as the only evidence you can rely on.
FAQ
Is a low TPS always caused by the anticheat?
No. TPS is a summary. Entities, chunk loading, redstone, and other plugins can lower it. Use a profile to see which owner uses the time.
Why does tick time spike when my anticheat logs many alerts?
Alert handling and logging can add work, especially if output is verbose or sent to a slow destination. Compare a run with logging reduced on staging to separate the logging cost from the check cost.
How long should a spark capture run?
Capture long enough to include the spike or the steady load you are investigating, and no longer. Long captures are harder to read and create larger reports.