Your Lovable or Claude-Built App Is Not Production Ready Yet: The Checklist
An app built with Lovable, Claude Code, Bolt or Replit is usually functional but not safe to launch. The four gaps that show up almost every time are missing or permissive Supabase row level security policies, API keys exposed in client-side code, no server-side validation behind the UI checks, and no backup or deploy process. You can check all four yourself in about an hour, and the row level security one is the gap that actually leaks customer data.
You built the app in Lovable, Bolt, Replit or Claude Code. It works. You can sign up, log in, click through, and the data saves. Now you want real customers in it.
The gap between "it works" and "it is safe to launch" is usually four things. None of them are visible from using the app. You can check all four in about an hour.
1. Check your Supabase row level security policies
This is the one that leaks customer data.
Supabase exposes your Postgres database straight to the browser. The only thing between a logged-in user and every row in your database is row level security. If RLS is off, or the policy is permissive, anyone with an account can read everyone else's records using the browser dev tools.
List every unprotected table:
select tablename, rowsecurity
from pg_tables
where schemaname = 'public' and rowsecurity = false;
Then find policies that are technically on but allow everything:
select tablename, policyname, cmd, qual
from pg_policies
where schemaname = 'public';
A qual of true permits every row. Same as no policy, written to look like one.
A correct policy for a table where each row belongs to one user:
alter table public.projects enable row level security;
create policy "owner reads own projects"
on public.projects for select
using (auth.uid() = user_id);
create policy "owner writes own projects"
on public.projects for insert
with check (auth.uid() = user_id);
select, insert, update and delete each need their own policy. The common AI-generated mistake is a correct select policy with update and delete left open, so users read only their own rows but can delete anybody's.
Test it. Make two accounts. Logged in as the second, try to read the first one's data in the browser console:
const { data } = await supabase.from('projects').select('*').eq('id', 'other-users-id');
An empty array is correct. A returned row means your policy does not work.
2. Find the API keys you published to the internet
Everything in your frontend bundle is public. The browser downloaded it.
Supabase gives you two keys. The anon key is meant to be public and is fine in the browser, provided RLS actually works. The service_role key bypasses RLS completely and must never reach the browser.
Open your deployed site, open DevTools, go to Sources, and search all files for service_role, sk-, and anything named SECRET. In Next.js and Vite, any variable prefixed NEXT_PUBLIC_ or VITE_ is deliberately bundled into the browser, so a secret with one of those prefixes is public.
If you find one, rotate it. Changing the code is not enough, since the old key is in your git history.
3. Add server-side validation behind every UI check
AI builders put validation in the form. The form runs in the browser, and the browser belongs to the user. Anyone can skip your form and call the API directly.
For every write in your app, ask whether the server would notice a request with different values:
- Can a request set a price to zero or a negative number?
- Can a user send
role: "admin"in a profile update and have it saved? - Can a user create a record pointing at someone else's id?
That third one catches people constantly. If profiles has a role column and users can update their own profile row, they can promote themselves to admin. Move roles to a table users cannot write to.
4. Get a deploy and a backup you have tested
Pushing to main should deploy. The test is whether someone other than you could ship a one-line fix today.
Supabase gives daily backups on paid plans. Free projects get no point-in-time recovery and pause after a week of inactivity. If the app holds customer data, pay for the plan and restore the backup once to a scratch project so you know it works.
Add Sentry or similar. Twenty minutes, and without it the only way you learn a page is broken is a customer telling you.
Why your AI coding assistant keeps breaking things it fixed
Two causes. There are no tests, so nothing catches the regression. And the context window cannot hold your whole codebase, so the assistant rewrites functions without seeing what calls them.
Add tests around whatever keeps breaking, and split large files. Stopping to add tests feels like going backwards and is almost always faster.
The one hour version
- Run the two SQL queries. Fix any table with RLS off or a policy of
true. - Search your deployed bundle for
service_roleandsk-. Rotate anything you find. - Make a second account and try to read the first one's data. It should fail.
- Check whether a user can change their own role or a price.
- Turn on backups and confirm you can deploy from a clean push.
When to hire a developer instead
Some of this is worth paying for rather than learning under deadline:
- The app already holds real customer data, particularly health, financial or identity data
- An enterprise buyer has sent you a security questionnaire
- Payments are involved and amounts are set anywhere the user can reach
- Auth needs rebuilding rather than patching
- Your remaining-work estimate keeps growing instead of shrinking
What to search for. The useful terms are "Supabase security audit", "Lovable developer", "Next.js Supabase developer", or "take AI-built MVP to production". A full-stack developer who has not worked with Supabase RLS specifically will spend your money learning it.
What it costs. A review runs around $150 to $400. A review plus the fixes runs around $800 to $1,500. Three days to two weeks, depending on how much data the app already holds.
What you almost never need is a rewrite. The generated code is ordinary React, TypeScript and Postgres, and it is repairable. What usually needs replacing is the authorisation layer and anything touching money. That is days, not months.
Get it checked
We do this as a fixed-scope hardening pass: audit, written findings, then the fixes. Backend engineering covers the auth and data model work and cloud and DevOps covers deploys and backups. The SaaS customer portal case study shows a multi-tenant app with the permissions done properly.
Still pricing the build? How much it costs to build an MVP covers what to budget, including this pass.
Common questions
- Is a Lovable app production ready?
- Usually not without a review. Lovable produces working React and Supabase code quickly, but it does not reliably write restrictive row level security policies, keep secrets off the client, or validate input on the server. Those three gaps are what make an app unsafe to put real customer data into, and none of them are visible from using the app.
- How do I check if my Supabase app is secure?
- Open the Supabase dashboard, go to Authentication then Policies, and look for any table holding user data that either has row level security disabled or has a policy with a USING clause of true. Both mean any logged-in user can read every row in that table. Then open your deployed site, view source, and search the JavaScript bundle for 'service_role' and 'sk-'. Either one appearing there means the key is public and must be rotated.
- What does it cost to make an AI-built app production ready?
- A focused hardening pass on a small app usually runs a few hundred to a couple of thousand dollars and takes three days to two weeks. The cost depends on how much data the app already holds and whether auth needs rebuilding rather than patching. Postings for this exact work currently range from around $145 for a review to $1,500 for a full security review plus fixes.
- Why does my AI coding assistant keep breaking things it already fixed?
- Because there are no tests, so nothing detects the regression, and because the context window cannot hold the whole codebase, so the assistant rewrites code it cannot see the callers of. The fix is to add tests around the parts that keep breaking and to work in smaller, more isolated files, which gives the assistant a smaller surface to get wrong.
- Where can I hire a developer to make my Lovable app production ready?
- Search for a Supabase security audit, a Lovable developer, or a Next.js and Supabase developer rather than a general full-stack developer, because row level security is the specific skill that matters here and someone who has not used it will learn it on your budget. Ask for a product they have shipped on Supabase and ask how they test that one tenant cannot read another tenant's rows. Expect $150 to $400 for a review and $800 to $1,500 for the review plus fixes.
- Should I rebuild my AI-built app from scratch?
- Rarely. The generated code is usually ordinary React, TypeScript and Postgres, which is repairable. What typically needs replacing is the authorisation layer and anything handling payments or personal data. Rebuilding the whole thing restarts the clock on every bug already found and fixed, and it is slower than it looks.
Want this looked at properly?
Tell us what you're working with. We'll give you a straight answer in a 30-minute call, free.