SupaForge vs. Supabase CLI db diff
Two live environments, the whole project - not just the schema.
npm install -g @akal/supaforge. A hosted dashboard is on the way - to hear when it opens.What supabase db diff Does
supabase db diff compares a database with the schema your migration files produce, and writes the DDL that turns one into the other. It's the natural tool for a local-first workflow: change the local database, diff, commit the migration.
Its scope is the Postgres schema. Many teams also change things in the dashboard - auth settings, storage buckets, cron jobs - and that's where it stops.
What SupaForge Adds
SupaForge compares two live environments - staging and production, a branch and production, or any pair - across the whole project:
- Postgres schema - powered by DBDiff
- Reference data - the rows of the tables you choose
- RLS - policies, and tables with RLS switched off
- Roles and grants - including
anon,authenticatedandservice_role - Auth configuration, storage and Edge Functions
- Cron jobs, webhooks, Realtime, Vault and extensions
- Queues and pg_partman partition sets
- Migration history - local files against what the target has applied
| Feature | supabase db diff | SupaForge |
|---|---|---|
| Schema | ✅ DDL | ✅ DDL, via DBDiff |
| Reference data | - | ✅ Row by row |
| Roles & grants | - | ✅ |
| Auth settings | - | ✅ |
| Storage buckets | - | ✅ Settings and policies |
| Cron, webhooks, Realtime, Vault | - | ✅ |
| Edge Functions | - | ✅ Deployed versions |
| Compares | A database with your migrations | Any two environments, or a directory of schema files with one |
| Applying | Commit and push the migration | diff --apply, in one transaction, with --prove |
| Summary | The generated SQL | Drift score, severities, CI annotations |
Example
npm install -g @akal/supaforge{
"environments": {
"staging": {
"dbUrl": "$STAGING_DATABASE_URL",
"projectRef": "STAGING_REF",
"accessToken": "$SUPABASE_ACCESS_TOKEN"
},
"production": {
"dbUrl": "$PRODUCTION_DATABASE_URL",
"projectRef": "PROD_REF",
"accessToken": "$SUPABASE_ACCESS_TOKEN"
}
},
"source": "staging",
"target": "production"
}supaforge diffsupaforge diff --check=authsupaforge diff --check=storageWhen to Use supabase db diff
If every change goes through migration files and nobody touches the dashboard, supabase db diff is a fine way to write those migrations. SupaForge complements it by checking that the environments really match - including everything that isn't schema.
Summary
supabase db diff writes schema migrations. SupaForge compares any two live environments across the whole project and fixes the target safely - the better fit for teams that use the dashboard alongside code.
Ready to try SupaForge?
Install the CLI and run your first diff in a minute. Nothing is changed until you add --apply.
npm install -g @akal/supaforge