Guide · Supabase
Supabase "permission denied for table" (42501)
Updated
A save fails, a list comes back empty or sign-up breaks, and the response says code 42501, "permission denied for table".
Why it happens
Supabase announced that new tables in the public schema are not reachable through the API until access is granted, and it applies this to all existing projects from 30 October 2026. Newer projects may see it earlier. Tables you already have keep their current access.
Possible causes
- A new table was created without granting access to the roles the API uses.
- Access was granted to one role (for example signed-out visitors) but not the one the app uses (signed-in users), or the other way round.
- It is a row-level security problem instead: the same code 42501 is also returned when a rule blocks the row, but then the message reads "new row violates row-level security policy".
- A table with an auto-numbered column is missing access to its sequence.
- An AI builder or script created the table and did not include the access it needs.
You can't see it yourself
You're signed in, your customers aren't. Tables you made earlier keep working, so your old test data looks fine. The table added most recently is the one that fails for everyone.
Related: Data won't save: "new row violates row-level security policy" · Edits or upserts blocked by row-level security · Users can see other users' data in my Lovable app
VibeFix is independent. Lovable, Bolt, Replit, Base44, v0, Supabase, Firebase, Stripe and Vercel are trademarks of their owners.
Want it fixed?
Our AI agent finds the cause, fixes it in your code and re-checks your live app. $79 for one bug, paid up front. If we can't complete your re-check, you get your money back.
It starts with a free check that confirms the problem on your live app, no account needed.