Skip to content
Strata Sync

AI agents: fetch the documentation index at llms.txt. Markdown versions are available by appending .md to any page URL, including this page's markdown.

Introduction

Build instant, offline-capable apps that sync with Strata Sync.

A local-first sync engine for TypeScript, React, and Next.js. Reads come from a local store, so the UI stays fast. Writes queue offline and sync when you reconnect. A server-sequenced log ensures every client converges.

Built on the sync architecture Linear described but never open-sourced, extended with Yjs CRDT collaboration, undo/redo, and pluggable adapters.

Key features

  • Local-first reads: render from IndexedDB, no network round-trips
  • Server-sequenced consistency: a monotonic syncId orders all changes globally
  • MobX reactivity: only re-renders components that read changed fields
  • Offline writes: a persistent outbox replays mutations on reconnect
  • Rich-text collaboration: Yjs CRDT for multi-user editing
  • Undo/redo: transaction-based history tracking
  • Field-level conflict resolution: LWW rebase with configurable strategies
  • Partial replication: load strategies control eager vs. on-demand sync
  • Type-safe schema: decorators define models, typed hooks bind them to React

What you can build

Strata Sync fits products that need local-first responsiveness with predictable sync:

  • Collaborative editors with offline draft support
  • Task and project apps that must work on unreliable networks
  • Customer-facing dashboards backed by a shared canonical state
  • Mobile workflows that queue writes and reconcile after reconnecting
  • Internal tools that need strong consistency without giving up responsiveness

How it works

  1. Define models with decorators (@ClientModel, @Property, @ManyToOne, @OneToMany).
  2. Create a sync client with storage, transport, and reactivity adapters.
  3. Wrap your React tree with SyncProvider.
  4. Read data with hooks (useModel, useQuery) that auto-update.
  5. Write data with create, update, and delete: applied optimistically, synced in the background.

How Strata Sync compares

FeatureStrata SyncElectricSQLZeroInstantDBPowerSync
Local storageBuilt-in (IndexedDB)Bring your ownBuilt-in (IndexedDB)Built-in (IndexedDB)Built-in (SQLite)
Conflict resolutionAutomatic, field-levelBring your ownServer decidesServer decidesCustomisable
Real-time editingRich-text with YjsNot includedNot includedNot includedNot included
Offline writesFull offline supportBring your ownNot supportedBasic supportFull offline support
Undo / redoBuilt-inNot includedNot includedNot includedNot included

Packages

Install only the packages you need.

PackageDescription
@stratasync/coreModel runtime, schema decorators, transactions
@stratasync/clientClient orchestrator, CRUD, query engine, outbox
@stratasync/reactReact hooks and SyncProvider binding
@stratasync/nextNext.js App Router SSR bootstrap and serialization
@stratasync/y-docYjs CRDT document and presence management
@stratasync/mobxMobX reactivity adapter for observable models
@stratasync/storage-idbIndexedDB storage for data, outbox, and metadata
@stratasync/transport-graphqlGraphQL + WebSocket transport for sync and mutations