Supabase database
24,664 Lovable sites sent data without a login. Is yours one of them?
Run the query below in your Supabase SQL editor. It lists every table and view that a visitor who is not logged in can read, and flags the ones with email, phone or address columns. Those are the tables the Crissy Field study counted. If the list is empty, or shows only things you mean to publish, like a product catalogue, your app isn’t one of the sites the study describes.
TL;DR
- Crissy Field and Handelsblatt looked at 159,041 Lovable projects in Common Crawl. 34,545 used Supabase, and 24,664 sent database records to visitors who weren’t logged in. In 7,403 of those (30%), the records included email addresses.
- The authors say 30% is not a confirmed leak rate, because some tables are meant to be public. Our own lab study of 318 apps, built a different way, came out close: 31% raw on our 24 Nov 2026 re-check, about 25–27% after false alarms.
- Supabase’s change on 30 October 2026 only affects new tables. Tables that already existed keep their access, so apps already live are not fixed by it.
- One SQL query, tested on Postgres 17 and 18, shows what a logged-out visitor can read. Fix each row with RLS, a policy, or a revoke, then check again.
This guide is for people who built an app with Lovable (or any builder that uses Supabase) and saw the study on Hacker News or in Handelsblatt. The study’s figures come from the Crissy Field report. Supabase’s and Lovable’s positions come from their own changelogs and docs, linked at the end. Every check here runs on your own project. Don’t point it at anyone else’s app.
What did the study measure?
| Count | What was counted |
|---|---|
| 159,041 | Lovable projects found. Sites in Common Crawl, the open web archive, from December 2025 to September 2026 |
| 34,545 | Used Supabase. The page loaded data from a Supabase project |
| 24,664 | Sent records without a login. A visitor who wasn’t logged in received rows from the database |
| 7,403 (30%) | Records included email addresses. Email-looking values in 10,560 tables across these sites |
The authors say plainly that 30% “should not be read as a confirmed data leak rate”, and that a Common Crawl sample doesn’t represent every Lovable app. Some sites are meant to show emails, such as a business’s own contact address. The cases the report describes go well beyond that: a forum with more than 80,000 profiles and 200,000 chat messages, sales records, and over 1,000 identity-document records.
Does it match other research?
It does, which is the uncomfortable part. Our lab study took the opposite route. We didn’t look at live sites at all. We rebuilt 318 public Lovable and Supabase apps from their own migration files in a lab database, then tested what a visitor and a signed-in stranger could read.
| Crissy Field and PatchLabs, both Nov 2026 | |
|---|---|
| Source | Crissy Field: Live sites in Common Crawl PatchLabs lab: Public repos, rebuilt from migrations |
| Who was tested | Crissy Field: A visitor who isn’t logged in PatchLabs lab: A visitor, and a stranger who signs up |
| Signal | Crissy Field: Email addresses in returned records PatchLabs lab: Personal data readable by the wrong person |
| Rate | Crissy Field: 30% of sites sending records PatchLabs lab: 31% raw (24 Nov 2026 re-check), about 25–27% after false alarms |
Two different methods, two different samples, and both land at roughly one app in four or worse. So this isn’t one researcher’s quirk. It’s what happens when an app reads its database straight from the browser and a table’s rules aren’t set.
Why does a Lovable app send data to strangers?
Your app’s browser code talks to Supabase directly, using the public anon key. That key is meant to be public (see is the Supabase anon key safe?). What protects the data is three things on each table, checked in this order:
- Grant. Can the
anonrole reach the table at all? Until recently every table inpublicgot this automatically. - Row level security. Is RLS on? If it’s off, a grant means every row.
- Policies. If RLS is on, which rows does a policy allow? A policy of
using (true)for anon means every row again.
Views are a fourth way in. A normal view runs as its owner, so it skips the RLS on the tables under it, unless it was created with security_invoker (see views and security_invoker).
Didn’t Supabase fix this on 30 October?
Only for new tables. Supabase’s breaking-change notice says that from 30 October 2026, new tables in existing projects are no longer exposed to the Data API until you grant access. (New projects have worked this way since 30 May.) But it also says existing tables “keep their current grants and stay reachable”. Every site in the study was crawled before September, so their tables are existing tables. The change doesn’t touch them.
There’s a second catch. When a new table doesn’t work in your app, the quickest fix an AI builder can write is grant select on … to anon. That brings back exactly the access the change took away, and RLS still has to be on with a real policy behind it.
What about Lovable’s security scan?
Lovable’s security docs describe a Quick scan that runs on every publish and flags things like tables without RLS, and a Deep scan you start yourself. Findings can be fixed with “Try to fix all”, using a small daily allowance of free fixes. Auto-fix is opt-in, and a setting to block publishing while critical findings are open is off by default. On 12 November Lovable added a review of critical findings before publishing.
Run it, it’s free. But it looks for missing RLS. A table with RLS on and a using (true) policy, or a view that skips RLS, needs the check below as well. Lovable’s own docs say the scans can’t guarantee complete security.
How do I check my own app? (2 minutes)
Open your project in the Supabase dashboard, go to the SQL editor, and run this. It reads only the database catalog, not your data, and changes nothing.
-- Which tables and views would hand rows to a visitor who is not logged in?
with rel as (
select c.oid, c.relname, c.relkind, c.relrowsecurity as rls,
coalesce(c.reloptions, '{}') as opts
from pg_class c join pg_namespace n on n.oid = c.relnamespace
where n.nspname = 'public' and c.relkind in ('r','v','m','p')
),
open_policy as (
select tablename, string_agg(policyname, ', ') as names
from pg_policies
where schemaname = 'public' and cmd in ('SELECT','ALL')
and roles && array['anon','public']::name[] and qual = 'true'
group by tablename
)
select r.relname as name,
case r.relkind when 'v' then 'view' when 'm' then 'matview' else 'table' end as kind,
case
when r.relkind = 'm' then 'materialized view: RLS never applies'
when r.relkind = 'v' then 'view runs as its owner, so RLS on the tables under it is skipped'
when not r.rls then 'RLS is off'
else 'a policy allows every row: ' || p.names
end as why,
(select string_agg(a.attname, ', ') from pg_attribute a
where a.attrelid = r.oid and a.attnum > 0 and not a.attisdropped
and a.attname ~* '(e_?mail|phone|passport|address|birth|iban|ssn|national_id)') as personal_columns
from rel r left join open_policy p on p.tablename = r.relname
where has_table_privilege('anon', r.oid, 'SELECT')
and ( r.relkind = 'm'
or (r.relkind = 'v' and not (opts && array['security_invoker=true','security_invoker=on']))
or (r.relkind in ('r','p') and not r.rls)
or p.names is not null )
order by 4 nulls last, 1;We tested it on Postgres 17 (what Supabase runs) and 18, against a database with one table of each kind. It listed exactly the tables and views that a real query as anon could read, and left out the safe ones: RLS on with owner-only policies, RLS on with no policies, the grant revoked, and a security_invoker view.
How do I read the result?
| You see | What it means, and what to do |
|---|---|
| No rows | No table or view hands every row to a logged-out visitor. Do: Run it again after each new table. Then test signed-in strangers (below). |
| A row with no personal-looking columns | Readable by anyone. Fine if it’s meant to be, like products or blog posts. Do: Make sure nothing private gets added to it later |
| “RLS is off” with personal columns | Anyone with your public key can read every row. Do: Turn RLS on and add owner-only policies (see RLS policies explained) |
| “a policy allows every row” | RLS is on, but the policy allows everything. Do: Replace using (true) with a rule tied to the user, like auth.uid() = user_id |
| A view | The view bypasses the RLS on its tables. Do: alter view … set (security_invoker = true); or revoke anon’s access to the view |
Two limits, so you know what this query doesn’t see. It only flags policies that allow everything. A policy with a condition, like status = 'published', still deserves a read. And it only covers logged-out visitors. To check what a stranger who signs up can see, change 'anon' to 'authenticated' in both places and look again. In our lab study, 32 of the 97 leaking apps leaked only to signed-in strangers (24 Nov 2026 re-check).
How do I fix a table it lists?
For a table that holds user data, in the SQL editor:
-- Turn row level security on (with no policy, nobody can read it through the API)
alter table public.signups enable row level security;
-- Then let each signed-in user read only their own rows
create policy "own rows" on public.signups
for select to authenticated
using ((select auth.uid()) = user_id);
-- If logged-out visitors never need this table, remove their access entirely
revoke all on public.signups from anon;Use your own table and column names. If your app breaks afterwards, that tells you which screen was reading data it shouldn’t have. Fix the screen, don’t loosen the rule. If you’re building in Lovable, you can paste the query result into the chat and ask it to make these changes, then run the query again to confirm the rows have gone.
If a table did contain personal data that strangers could read, assume it may have been copied. The first hour after a leak covers what to note down and who to tell.
Sources
- Crissy Field: Lovable, many apps built on the platform expose sensitive data (Nov 2026; cites Handelsblatt, 2 Nov 2026)
- Supabase: tables not exposed to the Data and GraphQL API automatically (28 Apr 2026; existing projects from 30 Oct 2026)
- Supabase: tables (the Table Editor turns RLS on for you; SQL doesn’t)
- Lovable: security and the Lovable changelog (12 Nov 2026 entry)
- PatchLabs lab study: method (318 apps, Nov 2026)
Related findings
The checks behind this guide, each with example code, a self-check and the fix.
Anonymous visitor can read personal data
PL-008Row level security not enabled
PL-003RLS enabled but no policies (owner locked out)
PL-005Always-true policy
Free check
Check your app for this, free.
Paste your public repo. PatchLabs rebuilds your database from its migrations, tests it as a visitor, a stranger and the owner, reads the code for keys and risky patterns, and hands you the fix.
Written by Manraj Singh Dhillon. Last checked 14 Nov 2026. Code samples are synthetic and run against your own project; nothing here names a real app. Spotted a mistake? Tell us.