© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
SupabaseS
Supabase•7mo ago•
2 replies
Eric

Vault secrets table grants missing on remote despite migration

Hey everyone — I'm running into an issue with Supabase migrations.

I have a local setup with a single init migration that includes explicit GRANT statements for the vault.secrets table (e.g., GRANT INSERT, UPDATE ON vault.secrets TO service_role). On local, everything works and the grants are applied correctly.

However, when the same migration is applied on the remote project (via Supabase’s branching workflow), the grants for service_role are not applied. I did not use db push or db pull at any point — only the migration SQL file.

I’ve verified that:

The vault.secrets table is created in the migration.

The grants are included after the table creation in the same file.

The service_role still lacks INSERT/UPDATE privileges on remote.

Is there something special about the vault schema that blocks permission grants remotely? Or are there known limitations in applying grants through migrations in remote Supabase environments?

Any insights or workarounds appreciated! Thanks 🙏
Supabase banner
SupabaseJoin
Supabase gives you the tools, documentation, and community that makes managing databases, authentication, and backend infrastructure a lot less overwhelming.
45,816Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Programatically Delete Vault Secrets
SupabaseSSupabase / help-and-questions
13mo ago
Vault - Creating secrets in edge functions
SupabaseSSupabase / help-and-questions
6mo ago
Migration File Clean Up on Remote
SupabaseSSupabase / help-and-questions
7mo ago
Adding Supabase Vault Secrets extension to local development
SupabaseSSupabase / help-and-questions
4y ago