Why 3 Credits Costs 3x More
When you have 370 tables, you're not buying a script. You're buying insurance.
Complex migrations aren’t about running a script—they’re about preserving relationships, security policies, and business logic that grew organically. One wrong move and months of user data could be at risk.
The Real Cost Breakdown
Here’s where your 3 credits ($237) go:Analysis & Planning (0.5 credits)
Before touching anything, we map the battlefield:
- Schema inventory (every table, column, relationship)
- RLS policy audit (security vulnerabilities)
- Data volume assessment (GB to transfer)
- Complexity scoring (simple vs. nested relationships)
- Risk identification (what could break)
- Migration strategy (order of operations)
Schema Migration (0.5 credits)
Recreating your database structure:
- Table definitions (potentially hundreds of create statements)
- Foreign key relationships (mapping web of connections)
- Constraints & indexes (performance preservation)
- Custom types & enums (PostgreSQL specifics)
- Triggers & functions (business logic)
- Foreign key conflicts
- Constraint violations
- Data type mismatches
- Index corruption
Data Transfer (1 credit)
The heavy lifting:
- Batch extraction (not dumping everything at once)
- Relationship preservation (parent→child integrity)
- Binary data handling (images, files)
- JSON/JSONB integrity (complex nested data)
- Validation checks (every row verified)
- Error recovery (what if transfer fails mid-way?)
Security Migration (0.5 credits)
RLS policies—where most migrations fail:
- Policy extraction (parsing SQL logic)
- Security function migration (custom auth logic)
- Permission testing (verify it actually works)
- Vulnerability audit (are you more secure or less?)
- Edge case testing (what about null users?)
- One broken policy = data exposure
- One missing policy = unauthorized access
- One logic error = app broken for users
Auth Migration (0.5 credits)
User experience preservation:
- Account migration (metadata, OAuth links)
- Password reset strategy (communication plan)
- Testing user flows (sign-in, sign-up, recovery)
- Users need to reset passwords
- Email templates need updating
- Support documentation required
What Could Go Wrong (DIY Migration)
Data Corruption
Data Corruption
Scenario: You dump and restore without checking foreign keys.Result: Orphaned records, broken relationships, app crashes.Cost to fix: 40+ hours of manual cleanup, lost user trust.
Security Exposure
Security Exposure
Scenario: RLS policies don’t transfer correctly.Result: Users see each other’s data. GDPR violation. Legal liability.Cost to fix: Incident response, legal review, reputation damage.
Auth System Down
Auth System Down
Scenario: OAuth providers not reconfigured properly.Result: Users can’t log in. Support tickets flood in. Churn spikes.Cost to fix: Emergency hotfix, 24/7 support, lost revenue.
Performance Degradation
Performance Degradation
Scenario: Indexes not recreated. Queries that took 50ms now take 5s.Result: App feels broken. Users leave. SEO rankings drop.Cost to fix: Performance audit, query optimization, re-indexing.
Partial Migration
Partial Migration
Scenario: You migrate 300 tables but miss 70.Result: App works… mostly. Features randomly break. Data inconsistency.Cost to fix: Weeks of debugging, user complaints, patchwork fixes.
Why Complex Migrations Need Expert Handling
When Your Database Has 370 Tables, You're Buying Insurance
Complex migrations aren’t just about moving data—they’re about preserving relationships, security, and business logic that grew organically over months or years.
-
Deep Relationships: Foreign keys spanning dozens of tables
- One wrong order = orphaned records
- Circular dependencies require careful sequencing
- Self-referencing tables need special handling
-
RLS Policy Complexity: Security rules that reference multiple tables
- Policies spanning junction tables
- Custom security functions
- Permission dependencies
-
Business Logic in Database: Functions and triggers
- Automated workflows
- Data validation rules
- Audit logging
-
Scale Matters:
- More tables = more things that can go wrong
- More data = longer transfer time = more risk
- More users = less tolerance for downtime
- Analysis & Planning (0.5 credits): Understanding your schema
- Schema Migration (0.5 credits): Recreating structure safely
- Data Transfer (1 credit): Moving data with validation
- Security Migration (0.5 credits): Porting RLS without gaps
- Auth & Testing (0.5 credits): Users and verification
What You Get for 3 Credits
Not just a migration. A complete infrastructure handoff:Migration Report
Complete audit trail:
- Every table migrated
- Row counts verified
- Relationship map
- RLS policy summary
- Testing results
Schema Documentation
Your database documented:
- ER diagrams
- Table descriptions
- Column definitions
- Index explanations
- Function docs
Environment Setup
Ready-to-use configuration:
- Connection strings
- Environment variables
- API endpoints
- Webhook configs
Testing Suite
Validation that it works:
- Automated tests
- Manual verification
- Security audit
- Performance baseline
- Edge case coverage
Communication Templates
User transition support:
- Password reset emails
- Migration announcement
- FAQ document
- Support responses
Rollback Plan
Safety net:
- Revert instructions
- Backup locations
- Emergency contacts
- Recovery timeline
Compare the Alternatives
| Approach | Cost | Risk | Time | Result |
|---|---|---|---|---|
| Our Migration (3 credits) | $237 | Low | 2-5 days | Production-ready |
| Hire Developer | $3,000+ | Medium | 1-2 weeks | Variable quality |
| DIY Migration | $0 (your time) | High | 3-4 weeks | Unknown |
| Stay on Lovable | $0 | Medium | — | Locked in |
- Your time: 80-120 hours × 8,000-12,000
- Opportunity cost: Features not built
- Risk: Data loss (incalculable)
- Stress: Learning migration tools under pressure
Who Needs This?
Pre-Launch Startups
Pre-Launch Startups
The situation: Built MVP in Lovable, now need to launch.Why 3 credits: Can’t launch on shared infrastructure. Need:
- Dedicated resources
- Custom domain
- Direct database access
- Full control
Growing Products
Growing Products
The situation: 100+ tables, hitting Lovable constraints.Why 3 credits: Need advanced features:
- Custom PostgreSQL extensions
- Complex RLS policies
- Real-time at scale
- Edge functions
Enterprise Teams
Enterprise Teams
The situation: Compliance, security, audit requirements.Why 3 credits: Can’t use shared backend:
- SOC 2 requirements
- Data residency needs
- Security audits
- SLA guarantees
The Bottom Line
3 credits = Insurance + Expertise + Time Saved
You’re not paying for a script. You’re paying for:
- 15+ years of combined database experience
- Tested migration processes
- Error handling and recovery
- Validation and verification
- Documentation and handoff
- What’s the cost of losing even 1% of your data?
- How many hours can your team afford to spend on migration?
- What’s the risk of breaking RLS and exposing user data?
- Can you afford downtime while you figure it out?
Still deciding? See what’s included or set up your Supabase project to get started.
