Guides / RLS Enabled No Policy

last checked nov 2026

Supabase "RLS Enabled No Policy": what it means and how to fix it

Security Advisor shows RLS Enabled No Policy (lint 0008_rls_enabled_no_policy). Supabase's Advisors docs summarize the same finding as No access rules defined. Row Level Security is on for the table, but there are no policies, so no data can be read or written through the API with your publishable key. That is a safe lock that breaks the app until you add policies (or an intentional deny-all policy). It is not an open table.

The short answer

Supabase's Security Advisor flags this as an INFO finding, not an ERROR. The official summary is "No access rules defined." The ramification, in Supabase's words: Row-Level Security is enabled but no policies exist, so no data can be read or written through the API.

Once RLS is enabled on a table and no policies exist, the publishable key (or legacy anon key) cannot reach that table's rows through the API until you create policies. Your empty screens and failed writes are the lock working. Do not disable RLS to clear this INFO finding. That would turn the table into the ERROR case covered by lint 0013.

Related Advisor findings you might see next to it:

Your publishable key is public by design. It is only safe when every exposed table has RLS and policies that match who should see which rows. With RLS on and no policy, that key reaches nothing on the flagged table.

How to check

1. Security Advisor (dashboard or CLI)

In the Supabase dashboard open Advisors → Security Advisor and look for lint 0008_rls_enabled_no_policy, titled "RLS Enabled No Policy" or summarized as "No access rules defined." From the CLI:

supabase db advisors

You can also pull advisors through the Management API or MCP get_advisors with type security. INFO findings can be intentional, so match each one against the access model you meant before you change anything.

2. List public tables with RLS on and zero policies

Run this in the SQL Editor. It prints table names only, never keys or row data. It joins pg_tables.rowsecurity with pg_policies so you see the no-policies condition Advisors is describing:

select t.tablename
from pg_tables t
where t.schemaname = 'public'
  and t.rowsecurity = true
  and not exists (
    select 1
    from pg_policies p
    where p.schemaname = t.schemaname
      and p.tablename = t.tablename
  )
order by t.tablename;

Any row in that result is the 0008 shape: RLS enabled, no policies on the table. Optionally list existing policies on a specific table:

select policyname, cmd, roles, permissive, qual, with_check
from pg_policies
where schemaname = 'public'
  and tablename = 'your_table'
order by policyname;

How to fix it

1. Add owner policies (most apps)

If the app should use the table through the Data API, create policies that match who can see which rows. Prefer naming the role with to, and wrap auth.uid() in (select …) so it runs once per statement. Postgres also checks grants before policies, so set both in the same change:

revoke all on table public.your_table from anon, authenticated;

-- Example: signed-in users manage their own rows; signed-out visitors get nothing.
grant select, insert, update, delete on table public.your_table to authenticated;

create policy "Users can view their own rows"
on public.your_table for select
to authenticated
using ( (select auth.uid()) = user_id );

create policy "Users can create their own rows"
on public.your_table for insert
to authenticated
with check ( (select auth.uid()) = user_id );

create policy "Users can update their own rows"
on public.your_table for update
to authenticated
using ( (select auth.uid()) = user_id )
with check ( (select auth.uid()) = user_id );

create policy "Users can delete their own rows"
on public.your_table for delete
to authenticated
using ( (select auth.uid()) = user_id );

Adapt the column name if your owner column is not user_id. For a longer checklist covering grants, the four-policy pattern, and supabase test db, see Supabase Row Level Security for vibe-coded apps.

2. Intentional deny-all (server-only table)

Some builders enable RLS with no policies on purpose so the Data API cannot reach the table. Supabase recommends making that intent explicit with a rejection policy instead of leaving the table policy-less (which keeps the INFO finding):

create policy none_shall_pass on public.your_table
for select
using (false);

With that policy, selects through the API still return nothing for roles the policy covers. Server-side work that must bypass RLS belongs behind a secret key (or legacy service_role) on a server or Edge Function you control. A secret key bypasses RLS only when the request carries no user access token; with a user JWT it runs under that user's policies. Never put a secret key in the browser. Do not print key values in logs or commands.

3. Keep RLS on

Do not alter table … disable row level security to silence this INFO finding. Disabling RLS on a public table is the ERROR path in lint 0013: anyone with the project URL can create, read, update, and delete every row. Keep RLS on and add the policies you intend (or the intentional deny).

Prove it / common mistakes

Turning protection off is not a fix. Disabling RLS to clear an empty result, an insert failure, or this INFO finding can make the table readable and writable by any role that still holds a grant, which on many projects includes anon. Keep RLS on and fix the policy.

next step

Want a second pair of eyes?

Grab the free Lockdown Pack (security rules for Cursor and Claude Code plus a pre-launch checklist), or have us check your repo with a $99 Scan + Report.

Sources

Every Postgres and Supabase detail above was checked against these official pages. Last checked Nov 2026. If behavior changed, the docs below are the source of truth.