Prototype to Production

Vibe Coding Security: What to Check Before Your App Goes Live

Illustration of vibe coding security, a database with a padlock badge

Vibe coding security comes down to three questions AI app builders rarely answer on their own: who can read your database, where your secret keys live, and whether signing in protects anything. Vibe coding means building an app by describing it to an AI tool such as Lovable, Bolt or Replit and keeping the code it writes. Answer them before real customers or real data arrive.

In late September 2026, UpGuard reported 16,326 databases whose tables anyone could read, found among about 300,000 websites using Supabase, the database many AI app builders set up for you. Over half held signs of personal data. The pattern behind them: AI coding agents built the sites, and their owners didn't know how the database was configured.

Why is vibe coding security so easy to miss?

Because an AI tool is rewarded for an app that works, and a demo never tests who else can get in. Veracode's 2026 report found that AI models now write code free of syntax errors nearly every time, yet about 44% of the tasks it tested produced a known vulnerability, barely changed from its first report.

Nobody has read a typical prototype's code, so vibe coding security depends on the checks below, not the tool.

Can anyone read your database?

More often than owners think. Supabase protects data with row-level security (RLS): rules inside the database that decide which rows each user may read or change. Supabase's documentation warns that a table without RLS can be read and changed by anyone with access to it, which can include visitors who never signed in. Supabase now turns RLS on for tables made in its dashboard, but UpGuard notes that tables an AI agent creates through code still start without it.

That makes the database the first vibe coding security check. Every table the app uses should have RLS on, with rules (Supabase calls them policies) written for how the app should behave. A rule that lets any visitor read every row is no protection unless the data is meant to be public. Lovable's Quick scan flags both on every publish; read its findings rather than clicking past them.

Are your secret keys sitting in the browser?

Anything the browser downloads, anyone can read. Supabase's guide to API keys describes two kinds. The publishable key (the older anon key) is meant to be public and only reaches what RLS allows. The secret key (formerly service_role) skips RLS entirely, so it must never appear in a browser, a mobile app or the code you keep on GitHub.

Keys to paid services are another vibe coding security slip. A prototype that calls OpenAI straight from the page hands its key to every visitor, who can then run up your bill. Those calls belong on the server, with the key stored as a secret. If a key was ever exposed, replace it and revoke the old one.

Does signing in actually protect each record?

Only if the app checks permissions on the server for every request. Broken access control, where people reach data or actions beyond their role, is number one in the OWASP Top 10, the standard list of web application risks. In OWASP's data, every application tested had some form of it.

Prototypes often hide a button instead of blocking the action behind it. Two quick tests show whether your app has this vibe coding security gap:

  1. Sign in as an ordinary user, open one of your records, and change the ID in the address bar to another record's.
  2. Open an admin page's address in a private window, signed out, and see what loads.

If either test shows you something you shouldn't see, anyone can see it.

What else does an app need before launch?

Leaks make the news, but vibe coding security also covers surviving a bad day:

  • Backups you have restored at least once.
  • Error alerts that reach a person.
  • Your own repository for the code, so you aren't tied to one tool.
  • A staging site for testing changes before customers see them.

When should you bring in a developer?

When the app holds anything you'd have to report if it leaked, such as customer records or payment details. An internal tool on sample data can wait. Lovable's security documentation says its scans don't replace a thorough security review, and it recommends a professional one for apps that handle sensitive data.

A vibe coding security review rarely means starting over. In Prototype to Production, we close the gaps above and keep what already works.

Frequently asked questions

Is vibe coding safe for a business app?

It can be, once someone has checked the gaps above. Most vibe coding security problems come from launching without those checks, not from the tools themselves.

Is Lovable secure?

Lovable catches common problems: its Quick scan runs on every publish, and a Deep scan, which you start yourself, reviews all of the code and looks for leaked secrets. Its documentation still makes you responsible for your app's security.

Is it a problem that my Supabase key is visible in the browser?

Not if it's the publishable or anon key and every table has RLS with sensible rules. The secret or service_role key should never appear there. Supabase is phasing out the anon and service_role keys by the end of 2026.

Can the AI fix its own security mistakes?

Often, if you point it at a specific finding, such as a table without RLS. Then test the fix the same way you found the problem.

Where to start this week

Start with the database, the vibe coding security gap that exposes the most at once. Confirm RLS is on for every table and run your builder's security scan. If the app already holds customer data, request a free audit and we'll show you what it needs before launch.

Let's build something that lasts.

Tell us what you're building, and we'll show you how we'd ship it.