Building Real-time Features with Supabase
Real-time features sell products, but they also break in spectacular ways if you do not respect the limits of the underlying broker. This playbook is how I add live subscriptions, presence, and optimistic updates to a React app using Supabase, without ending up with a UI that flickers on every reconnection. It covers schema design, RLS, presence, and the patterns that keep real-time work feeling instant rather than fragile.
Steps
Tools
Outcomes
Difficulty
Technologies used
The methodology
The phases, in order
Each phase below is something I actually run in a project. The descriptions are how I think about the work, not abstract definitions.
Phase
Supabase Project Setup
Phase
Schema with Real-time in Mind
Phase
Row Level Security Policies
Phase
Real-time Subscriptions
Phase
Presence and Cursors
Phase
Optimistic Updates and Conflict Handling
Phase
Observability and Failure Modes
Results
What You'll Achieve
Expected outcomes from implementing this playbook
Use this playbook
Want me to run this with you?
The playbook is the public version. The private version is me running it for your team against a real deadline. If you have a project on the line, that is usually the faster path.
Related insights
More on this thinking
Related blueprints
Reference architectures
Database
Related Playbooks
Other playbooks in this category
Managing Database Migrations
Database migrations are the part of the system where a tiny mistake creates an outage that lasts hours. This is the playbook I follow when migrating a production schema: expand-then-contract, dual writes when needed, idempotent scripts, a real rollback plan, and verification that does not depend on the migration tool reporting success. Boring on purpose, because exciting migrations are the dangerous ones.
Multi-Tenant SaaS Architecture
Multi-tenancy is one of the highest-leverage architectural decisions in a SaaS, and almost impossible to fix later. This playbook is the model I use to design tenant isolation that scales from ten customers to ten thousand: shared schema with row-level isolation, tenant-scoped routing, configuration, billing, and an admin layer that lets you operate the platform without breaking customer trust.
Choosing a Database in 2026
Database choice is one of the highest-cost, hardest-to-reverse technical decisions in a product. This playbook is the decision framework I walk teams through when they ask me to weigh in: define the workload first, pick a sensible default, evaluate hosted options on real criteria, plan for scale before you need it, prototype the hardest query, and document the choice so the next engineer does not have to relitigate it.