Let's talk

Why your game rubber-bands

Players call it lag. Almost every time, it's the server disagreeing with the client about where the character should be, then snapping the client back. Here's how to find which disagreement it is, in roughly the order you'll hit them.

What rubber-banding is

The Character Movement Component (CMC) predicts movement on the owning client. Each frame it records the move in an FSavedMove_Character, with the inputs, acceleration and final position. The server replays the same move and compares positions. If they differ by more than a small tolerance, the server sends a correction and the client snaps back, then replays its unacknowledged moves. Epic describes the full loop in Understanding networked movement in the CMC.

So rubber-banding is rarely "the network is slow." It's client and server computing different movement from the same input. Latency doesn't cause that. It only makes the snap longer and easier to see.

Step 1: prove it's a correction

Run a dedicated server with 2 clients at real latency (see test at real latency), then on the client:

INIconsole
p.NetShowCorrections 1
p.NetCorrectionLifetime 4

Each correction draws a debug capsule for where the client was and where the server put it. Play the moment players complain about. Then look at what you see:

  • Capsules appear, and your own character snaps. That's a correction. Go to step 2.
  • No capsules, but other players stutter. That's not a correction. It's smoothing or update rate on simulated proxies. Go to step 7.
  • No capsules, and everything freezes, then jumps. Suspect the server or bandwidth. Go to steps 5 and 6.

For a text trail, log LogNetPlayerMovement Verbose logs each correction with the timestamps involved.

Step 2: speed changed outside the move

This is the most common cause by a wide margin. Sprint, crouch-walk, slows, stamina and ability speed buffs that set MaxWalkSpeed on one machine only. The client runs at 600, the server still thinks 400, and every move fails the check. Forum threads report this exact pattern again and again (example).

An RPC that sets the speed on the server is a half fix. The RPC arrives later than the moves it should apply to, and moves replayed after a correction don't know about it.

The fix is to put the intent into the saved move, so both sides compute speed from the same per-move data:

C++RSMovementComponent.h
class FSavedMove_RS : public FSavedMove_Character
{
public:
    uint8 bSavedWantsToSprint : 1;

    virtual void Clear() override;
    virtual uint8 GetCompressedFlags() const override;
    virtual bool CanCombineWith(const FSavedMovePtr& NewMove, ACharacter* C, float MaxDelta) const override;
    virtual void SetMoveFor(ACharacter* C, float DeltaTime, FVector const& NewAccel,
                            FNetworkPredictionData_Client_Character& ClientData) override;
    virtual void PrepMoveFor(ACharacter* C) override;
};
C++RSMovementComponent.cpp
uint8 FSavedMove_RS::GetCompressedFlags() const
{
    uint8 Flags = Super::GetCompressedFlags();
    if (bSavedWantsToSprint) { Flags |= FLAG_Custom_0; }
    return Flags;
}

bool FSavedMove_RS::CanCombineWith(const FSavedMovePtr& NewMove, ACharacter* C, float MaxDelta) const
{
    // Never merge a sprint-start move into a walk move.
    if (bSavedWantsToSprint != static_cast<FSavedMove_RS*>(NewMove.Get())->bSavedWantsToSprint)
    {
        return false;
    }
    return Super::CanCombineWith(NewMove, C, MaxDelta);
}

void URSMovementComponent::UpdateFromCompressedFlags(uint8 Flags)
{
    Super::UpdateFromCompressedFlags(Flags);
    bWantsToSprint = (Flags & FSavedMove_Character::FLAG_Custom_0) != 0;
}

float URSMovementComponent::GetMaxSpeed() const
{
    const float Base = Super::GetMaxSpeed();
    return (bWantsToSprint && MovementMode == MOVE_Walking) ? Base * SprintMultiplier : Base;
}

SetMoveFor copies bWantsToSprint into the saved move, PrepMoveFor copies it back before a replay, and Clear resets it. You also need a client prediction data class whose AllocateNewMove returns FSavedMove_RS. Never write MaxWalkSpeed directly from gameplay code again.

GAS speed buffs

A MoveSpeed attribute changed by a gameplay effect reaches the client and the server at different moves. Even with a predicted effect, the moves around activation can disagree, and the CMC corrects them. For sustained buffs, have GetMaxSpeed read the attribute and accept one small correction at the start. For anything the player triggers with input (sprint, dash, aim-walk), drive it through a saved-move flag like the one above, and let GAS handle only cost, cooldown and tags.

Step 3: root motion that isn't networked

The CMC networks root motion from montages. "Root motion from everything" is the wrong mode for multiplayer, and community threads report corrections and sped-up animation when it's used on clients (example).

Check two things. Root motion mode is Root Motion from Montages Only. And the montage plays on the owning client and the server through the ability (PlayMontageAndWait), not from a multicast that reaches the owner a round trip late. For dashes and knockbacks, a Root Motion Source (ApplyRootMotionConstantForce and its siblings in GAS) is predicted and replayed properly.

Step 4: moves the CMC never saw

Anything that moves the character outside the CMC's simulation creates a position the other side never predicted:

  • SetActorLocation or TeleportTo on the client only (respawn, blink, interaction snap).
  • LaunchCharacter or AddImpulse called on one side.
  • Collision that differs between client and server: a client-only cosmetic mesh with collision, or a physics prop in a different place on each side.
  • Moving or rotating bases (UE-166232 is one engine-side example).

Rule: authoritative moves happen on the server. Predicted moves go through the CMC (a saved-move flag, or a root motion source). Cosmetic meshes get NoCollision.

Step 5: the server is hitching

If the server's frame takes 80 ms, it processes moves late in bursts, and every client sees a freeze, then a snap. That's no fault of the movement code. Check the dedicated server's own log and run stat unit on a listen server. Look for spikes when players join, when many abilities fire, or when AI spawns. A server that can't hold its tick rate rubber-bands everyone at once. Per-player rubber-banding points back at steps 2 to 4.

Step 6: bandwidth saturation

When a connection exceeds its rate limit, the engine delays or drops replication, and movement updates queue behind everything else. Run stat net and watch for saturation. The limits come from ConfiguredInternetSpeed and ConfiguredLanSpeed on the server, and MaxClientRate and MaxInternetClientRate on clients. An Epic forum reply puts the current defaults at 100,000. Older projects that upgraded through 4.2x still sometimes carry lower values in their config.

Raising the limits treats the symptom. The lasting fix is less traffic: fewer reliable RPCs per tick, a lower net update frequency for actors nobody looks at, and no per-frame replicated properties that only the UI reads.

Step 7: other players stutter

If your own character is fine but other players hop or jitter, that's simulated proxy smoothing, not a correction. Check:

  • Network smoothing mode on the CMC is Exponential (the default). Linear and Disabled have their uses, but they show every gap.
  • Net update frequency on the character is high enough for its speed. Fast characters at a low rate look like they're teleporting.
  • Server tick rate: proxies can't update more often than the server ticks.

What not to do

Don't raise MAXPOSITIONERRORSQUARED or override ServerCheckClientError to return false. Both hide the corrections by letting the client decide where it is. That trades rubber-banding for desync and makes speed hacks trivial. Forum reports show the tolerance change rarely even hides the symptom (example).

The short version

  1. p.NetShowCorrections 1 at real latency. Corrections or proxies?
  2. Speed changes go through saved-move flags, never a raw MaxWalkSpeed write.
  3. Root motion from montages only, played on owner and server.
  4. Authoritative teleports on the server. Cosmetic meshes without collision.
  5. Server frame time is stable under load.
  6. stat net shows no saturation.
  7. Proxies: smoothing mode, update frequency, tick rate.

Start with steps 2 and 4. They're the usual causes. If your Steam reviews say "rubber-banding" and none of these steps finds it, a Diagnostic traces the correction to its cause in two days.

Still desyncing in packaged builds?

Free code fixes one symptom. A Diagnostic finds the cause across your project in two days.