If you're building a multiplayer game, the single most consequential architecture decision you'll make is how you synchronize players: state synchronization, where a server holds the authoritative game state and pushes updates to clients, or frame synchronization (lockstep), where clients exchange only inputs and each machine computes the game independently. The trade-offs are stark. State synchronization buys you security and cheat resistance at the cost of heavy server load and network traffic. Lockstep buys you cheap, low-bandwidth networking at the cost of client-side authority that cheaters can exploit. Here's how to decide which fits your game.

Understanding Game State Synchronization: State vs. Frame

In state synchronization, one node—the server—owns the truth. As a research framework on cheating detection in multiplayer online games describes it, "the server maintains the authoritative game state based on the updates received from clients and synchronizes the clients' states accordingly." Clients send their actions upward, the server resolves them, and the resulting state flows back down. What each player sees is, by definition, what the server says happened.

Frame synchronization inverts this. Players send only their inputs—button presses, movement commands—and every client runs the same deterministic simulation on those inputs. Ruoyu Sun, writing on game networking architecture, notes that this approach makes deterministic logic "necessary" rather than optional: every machine must compute exactly the same result from the same inputs, or the game desynchronizes. The server, if there is one, is mostly a relay.

The two models also diverge in recovery. Sun's comparison highlights that reconnecting under state synchronization is "relatively easy"—the returning player simply retrieves the latest game state from the authoritative node. Under input synchronization, reconnect is "relatively difficult," because a relay node must store all inputs and replay them on the player's side. That difference matters for long sessions and unstable connections.