PatchPaste · Guides
Last updated 30 October 2026
Is my Lovable or Bolt app secure? A 10-minute pre-launch checklist
AI builders like Lovable, Bolt and Cursor get you to a working app fast. They don't always get you to a safe one. Run through these checks before you share your link. You don't need to be a developer to follow them.
.env or .git files online, RLS on every table, private files in private buckets, and the server (not a hidden button) blocks what users shouldn't do. Or scan your live app free for the outside checks.1. Search your live JavaScript for secret keys (2 min)
Open your live site in a private window → dev tools → Sources, and search all files (Ctrl/Cmd + Shift + F) for:
service_roleandsb_secret_(Supabase admin keys)sk_live(Stripe secret key)sk-followed by a long string (OpenAI and other AI keys)AKIA(AWS) andghp_(GitHub)
Fine to see: the Supabase anon or publishable key, and the Stripe pk_live_ key. Not fine: anything in the list above. Move the code that uses it to an Edge Function or server route, then replace the key. Remember that VITE_ and NEXT_PUBLIC_ values always end up in the browser. More: are VITE_ variables secret? and is the anon key safe?
2. Make sure private files aren't public (1 min)
Visit these on your live domain:
/.env/.git/HEAD- A source map: take one of your JavaScript file URLs from the Sources tab and add
.mapto the end
Each should show a 404 or your normal app page, never the file's contents. If one shows real contents, treat every secret in it as leaked.
3. Turn on RLS for every Supabase table (3 min)
Go to Supabase → Table Editor. Any table marked RLS disabled can be reached by anyone with your public key. Turn RLS on and add policies like (select auth.uid()) = user_id.
Watch for using (true). AI tools often write it as a “fix”, and it makes the table public again. Views over user data should use security_invoker = true. Details: why using (true) makes your data public and how to check your RLS.
4. Check storage buckets (1 min)
Go to Supabase → Storage. Supabase says a public bucket skips access controls, so anyone with a file's URL can open it (Supabase docs: buckets). Private uploads, like IDs or invoices, belong in a private bucket with storage policies.
5. Try to break your own permissions (2 min)
Sign up as a second test user and try to:
- open another user's page or record by changing the ID in the URL
- visit admin pages (for example
/admin) as a normal user - change your own
is_admin,planorcreditsfield from the browser console
Hiding a button isn't security. The database or server must refuse the request.
6. Payments and webhooks (1 min)
If you use Stripe, make sure paid features are unlocked by a verified webhook on your server. Don't unlock them just because someone reached a /success page, because anyone can type that address.
7. Bonus: headers and rate limits
- Add security headers such as
Strict-Transport-Securityand aContent-Security-Policywhere your host lets you. - Think about rate limits or a CAPTCHA on sign-up, and on any route that calls a paid AI API, so one person can't run up your bill.
Pre-launch checklist FAQ
Is Lovable or Bolt itself insecure?
That's not usually where the problem is. Most problems come from settings in your own app: RLS turned off, secret keys in the frontend, or public storage. Those are yours to check, and this list covers the common ones.
My Supabase anon key is visible. Have I been hacked?
No. The anon or publishable key is meant to be public. What matters is whether Row Level Security limits what it can reach.
I found a leaked key. What do I do first?
Move the code that uses it to the server, make a new key there, then delete or revoke the old key at the provider. If you see signs it is being misused, revoke it straight away, even if a feature breaks for a while. Deleting it from your code alone is not enough.
How often should I re-check?
After every big change. AI edits can quietly undo an earlier fix, for example by turning RLS off or adding a key to the frontend.
Does a clean checklist mean my app can't be hacked?
No. These are the common mistakes in AI-built apps. A full security review or penetration test goes much deeper.
Get a free security report
Prefer an automatic check for steps 1, 2 and 7? Paste your URL. We search the JavaScript your site sends for secret keys (shown masked), check for exposed .env, .git and source map files, test common Supabase tables with your public key (read-only, at most one row, never stored), and check HTTPS and security headers. We never log in, so steps 4 to 6 are still yours to check. The report is free. Scans are free, so you can scan again after each AI edit.
Want to see one first? View a sample report.