Prompt
Supabase feels great for dev speed, but I'm worried about production limits. What should I know?
Latest observation
Supabase is great for getting to production fast, but the main thing to understand is that it’s really a managed Postgres + auth + storage + edge functions platform. That means your production risks are less about “Supabase can’t do it” and more about how you’ll scale, control costs, and avoid platform-specific bottlenecks.
Here’s what to watch.
1) Your main limit is still Postgres
Since Supabase sits on Postgres, the classic database constraints matter:
- Connection limits: too many concurrent DB connections can become a bottleneck.
- Query performance: slow queries, missing indexes, bad joins, and N+1 access patterns will hurt quickly.
- Storage growth: table bloat, large JSONB usage, and uncontrolled data growth can affect performance and cost.
- Migrations: schema changes on large tables can lock or slow things down if not planned carefully.
What to do:
Use proper indexes, monitor query plans, pool connections, archive old data, and test migrations on realistic data volumes.
2) Auth and row-level security are powerful, but can surprise you
Supabase’s RLS (Row Level Security) is a huge feature for production security, but it can also:
- Add complexity to debugging access issues
- Slow queries if policies are too complex
- Create “works in local/dev, fails in prod” surprises if policies aren’t tested well
What to do:
Keep policies simple, test them with real roles/users, and document expected access patterns.
3) Serverless/edge functions have runtime constraints
If you rely on Supabase Edge Functions, watch for:
- Execution time limits
- Memory/runtime limitations
- Cold starts in some scenarios
- Less flexibility than a full long-running backend
What to do:
Use edge functions for lightweight API logic, webhooks, and orchestration—not heavy jobs or long-running tasks.
4) Scaling is not “infinite by default”
Supabase can scale well, but at some point you may need to think about:
- Read replicas
- Database partitioning
- Caching layers (Redis, CDN, app-level caches)
- Background job systems
- Separating workloads across services
What to do:
Plan for a point where “one Postgres instance does everything” stops being enough.
5) Cost can rise with success
This is a big production concern.
Costs can increase from:
- Database size
- Compute tier upgrades
- Bandwidth/egress
- Storage
- Function invocations
- Too many realtime subscriptions or heavy usage patterns
What to do:
Set budget alerts, monitor usage, and test your app’s data transfer patterns before launch.
6) Vendor lock-in is real, but manageable
You’re not locked into “magic backend logic” as much as with some BaaS tools, because the core is Postgres. That said, you can still become dependent on:
- Supabase Auth patterns
- RLS policies
- Storage APIs
- Realtime features
- Edge Function conventions
What to do:
Keep business logic mostly in your app/domain layer, use standard SQL and Postgres features where possible, and avoid over-coupling to proprietary conveniences.
7) Operational visibility matters
In production, you’ll want:
- DB monitoring
- Slow query logs
- Error tracking
- Alerting for latency, connection saturation, and storage growth
- Backups and restore testing
What to do:
Treat Supabase like a real production database, not just a dev tool.
Practical rule of thumb
Supabase is often a great fit if:
- You want to move fast
- Your product is app/API-centric
- Your data model fits Postgres well
- You’re okay managing “real database concerns”
You should be more cautious if:
- You expect massive concurrency very quickly
- You need heavy background processing
- You have highly complex auth/tenant isolation rules
- You need very custom infrastructure or strict compliance controls
Best way to use it safely in production
- Start with Supabase
- Design like you’ll scale the DB
- Use RLS carefully
- Keep edge functions small
- Add observability early
- Test load and cost before launch
- Have an exit plan for critical data
If you want, I can also give you:
- a production readiness checklist for Supabase, or
- a “when Supabase stops being enough” scaling guide.