Back To Blog
Engineering

Real-Time Collaboration: How CRDTs Keep Everyone In Sync

Tomás Rivera September 3, 2026 7 Min Read
Real-Time Collaboration: How CRDTs Keep Everyone In Sync

Open A Vritti Document With A Teammate And You Will See Their Cursor Glide Across The Page, Their Edits Appear As They Type, And Your Own Changes Land Instantly Even On A Shaky Connection. It Feels Effortless. Underneath That Effortlessness Is One Of The More Elegant Ideas In Distributed Systems: The Conflict-Free Replicated Data Type, Or CRDT.

The Problem With Two People Typing

Imagine Two Editors Change The Same Sentence At The Same Time. A Naive System Has To Pick A Winner, And Someone's Work Vanishes. The Classic Alternative, Operational Transformation, Rewrites Each Edit Against Every Other Edit It Might Have Raced With. It Is Correct, But Famously Hard To Get Right And Brutal To Debug. We Wanted Something Simpler To Reason About And Robust To The Messy Reality Of Networks That Drop, Delay, And Reorder.

What A CRDT Actually Guarantees

A CRDT Is A Data Structure Designed So That Concurrent Edits Can Always Be Merged Into The Same Result, No Matter What Order They Arrive In. Each Change Carries Enough Identity, A Unique ID And A Position That Never Collides, So Any Two Replicas Which Have Seen The Same Set Of Changes End Up Byte-For-Byte Identical. No Central Referee, No Lost Writes.

  • Edits Commute: Apply Them In Any Order And You Converge To The Same Document.
  • Edits Are Idempotent: Receiving The Same Change Twice Is Harmless.
  • Offline Edits Merge Cleanly When You Reconnect, With No Manual Conflict Resolution.
  • No Single Server Has To Arbitrate; Peers Reconcile Themselves.

How Vritti Puts It To Work

Vritti's Editor Is Backed By A CRDT Library That Represents Your Document As A Sequence Of Uniquely-Identified Characters. A Lightweight Sync Service Relays Changes Between Everyone In A Document And Persists Them, So A Late-Joining Teammate Catches Up Instantly And An Offline Edit On A Train Merges The Moment You Are Back Online. Presence, Those Live Cursors And Avatars, Rides The Same Channel.

The Magic Of Real-Time Editing Isn't Speed. It's That No One Ever Has To Think About Conflicts. The Data Structure Makes Losing Work Impossible.

Why It Matters For You

You Will Probably Never Think About Any Of This, And That Is The Point. CRDTs Mean You Can Hand A Document To Ten People, Let Them Edit On Laptops And Phones Across Four Time Zones, And Trust That What You See Is What Everyone Sees. The Infrastructure Disappears, And Collaboration Just Works.

Great Collaboration Is Invisible When It Is Working. The Next Time A Teammate's Cursor Drifts Across Your Screen And Their Paragraph Appears Without A Hitch, You Will Know The Quiet, Careful Idea That Made It Possible.


Tomás Rivera Writes For The Vritti Team About Docs, Knowledge, And Publishing. Want To See Vritti In Action? Start Free.

Vritti

Start Building Your Team's Knowledge Home

Free To Start. No Credit Card Required. Bring Your Team In Minutes.