published fresh until

What does Supabase's Security Advisor flag and how do I fix it?

Summary As of October 2026, Supabase's advisors (deterministic lints) run from the dashboard Security Advisor, the CLI command supabase db advisors, or the MCP get_advisors tool. The ERROR-level lints include rls_disabled_in_public, security_definer_view, auth_users_exposed and rls_references_user_metadata, each with a documented fix.

Not for reviewing what each user can see (see supabase-rls-audit-before-launch); cross-tenant tests (see prove-tenant-isolation-supabase-cross-tenant-tests)

For your agent
claude mcp add --transport http --scope user whatworks https://whatworks.dev/mcp

Read-only, no account. Sign-in is only for trial reports: /connect.md

What this thread does

The problem

The Supabase dashboard (or an email) shows red items such as "RLS disabled in public", or you want your agent to check the project for the same issues before launch. You need to know what each finding means and what the fix is, without guessing.

Where to run it

From Supabase's database advisors page (read 18 October 2026):

  • Dashboard: the Security Advisor under your project's advisors section.
  • CLI: supabase db advisors.
  • MCP: the get_advisors tool with type security.
  • A Management API endpoint for security advisors.

The page says the checks are deterministic and some findings may be intentional, so compare each against your access model before changing anything.

The lints that matter most (docs, my paraphrase)

LintLevelMeaningDocumented fix
0013_rls_disabled_in_publicERRORTable in an exposed schema has no RLS; anyone with the project URL can read, edit and deleteEnable RLS and add policies, or stop exposing the schema
0007_policy_exists_rls_disabledINFOPolicies exist but RLS is off, so they do nothingEnable RLS
0008_rls_enabled_no_policyINFORLS on with no policy, so the API sees nothingAdd a policy, or an explicit deny if intended
0010_security_definer_viewERRORView runs with its owner's rights and bypasses RLSRecreate with security_invoker on
0002_auth_users_exposedERRORA view exposes auth.users dataUse a profiles table fed by a trigger
0015_rls_references_user_metadataERRORPolicy trusts user_metadata, which users can editBase the policy on trusted data
0024_permissive_rls_policyWARNA policy with an always-true conditionReplace with a real row condition
0028 and 0029WARNSECURITY DEFINER function callable by anon or authenticated through the RPC routeRevoke execute or switch to security invoker
0025_public_bucket_allows_listingWARNPublic bucket has a broad SELECT policy allowing the policy's roles to list filesDrop the broad policy or make the bucket private

Using it with an agent

A prompt that follows the docs: "Run supabase db advisors, group findings by level, and for each ERROR show the table or view and the smallest change that fixes it. Do not change policies yet; propose SQL migrations for me to review." Applying fixes to a live project is your call, not the agent's.

What the advisor does not do

It checks structure, not meaning. A policy that is always true is flagged, but a policy that checks the wrong column is not. For that, read policies against your access model and test as two users (neighbouring threads).

Not verified

I did not run the advisors against a real project here; the table is from the docs page.

Sources

  • Supabase docs, Database Advisors.

Started from a post by @Supabase docs, packaged by the editor. Original post

Subjects

More in security

For agents

Copy a short instruction for an agent that has WhatWorks connected, or open this page as Markdown.

# What does Supabase's Security Advisor flag and how do I fix it?
Summary: As of October 2026, Supabase's advisors (deterministic lints) run from the dashboard Security Advisor, the CLI command supabase db advisors, or the MCP get_advisors tool. The ERROR-level lints include rls_disabled_in_public, security_definer_view, auth_users_exposed and rls_references_user_metadata, each with a documented fix.
Copy for agent
get the whatworks thread supabase-security-advisor-rls-disabled-in-public-lints-how-to-fix and help me try it

Follow this thread

Following tells you when the verdict changes, a new version ships or a new option is added. Your agent mentions it the next time you ask WhatWorks.

Sign in with GitHub to follow. Nothing is posted for you.

Sign in with GitHub

Or ask your agent
follow the whatworks thread supabase-security-advisor-rls-disabled-in-public-lints-how-to-fix
WhatWorks

Connect your agent MCP

Paste this into your agent

Connect me to WhatWorks: add https://whatworks.dev/mcp/login and sign me in so I have an account. Steps: https://whatworks.dev/connect.md.

Or run this in your terminal
  • Claude Codeclaude mcp add --transport http --scope user whatworks https://whatworks.dev/mcp/login && claude mcp login whatworks
  • Codexcodex mcp add whatworks --url https://whatworks.dev/mcp/login && codex mcp login whatworks