Advanced

Designing anti-rollback protection for saves and offline progression

Rollback abuse happens when a player restores old local state. They may spend currency, open a chest, lose a fight, or claim a reward, then copy an older save back into place and try again.

Why old valid saves are still risky

A rollback save may be real. It may pass encryption and integrity checks because it was created by the game. The problem is not that the save is fake. The problem is that it is old and should no longer control the account.

This is why anti-rollback needs memory outside the local save. The backend should know the newest trusted account state, claimed rewards, spent currency, and important sequence numbers.

Use versions and sequence numbers

Give important saves a version or sequence number that only moves forward. The server stores the newest accepted number. If the client later sends an older number, the backend can reject or limit the sync.

This works best when the server creates or confirms the next trusted number. Client-only counters are helpful, but they can still be edited if the client is compromised.

A compact sync record could look like this:

sync-state.yml
1accountId: "player_123"
2serverSaveVersion: 42
3lastAcceptedClientVersion: 42
4lastTrustedServerTime: "2026-06-06T11:00:00Z"
5claimedRewardIds: ["daily_2026_06_06", "event_17_tier_04"]

If the player later uploads save version 39, the backend can tell that the client is trying to sync older state than the server already accepted.

Keep reward ledgers

Store important rewards as events. Daily reward claimed, battle pass tier claimed, loot chest opened, premium item purchased, crafting result accepted. If an old save tries to claim the same thing again, the server can see it already happened.

For random or expensive outcomes, store the accepted outcome too. For example, if a loot chest produced item 812, the server should remember that item 812 was the result. That stops players from restoring old saves until they get a better roll.

Use protected local storage

Local protection still matters. Runtime protection tools can make saves harder to edit and can detect broken state. This reduces easy tampering while the backend handles long-term truth.

Limit offline damage

Offline mode should have a maximum damage limit. Let players progress, but cap high-risk rewards. Premium currency, ranked points, tradeable items, and event prizes should be reconciled carefully when the player reconnects.

Example limits can be simple:

  • Only one daily reward can be queued while offline.
  • Premium currency changes need server approval before becoming final.
  • Offline event progress can advance, but tier rewards sync online.
  • Ranked progress is not accepted from offline sessions.

Handle conflicts clearly

If the server sees rollback, avoid confusing the player. Explain that the game could not sync older progress, keep the safest server state, and log the details. For repeated suspicious rollbacks, raise the trust level or restrict high-value offline actions.

Do

  • Use monotonic save versions, server counters, or progression sequence numbers.
  • Store reward claims and high-value actions in a backend ledger.
  • Limit what offline progress can change before server reconciliation.

Don't

  • Do not trust local save timestamps as the only rollback defense.
  • Do not let players reroll paid or scarce outcomes by restoring old saves.
  • Do not accept offline progress that is older than the server's known account state.
FAQ

Frequently asked questions.

Short answers to common questions developers ask after reading this article.