Vibe Coding
Vibe Coding Security Checklist: 17 Things to Audit Before Real Users
A security and production checklist for apps built with AI coding tools: secrets, auth, database rules, input validation, rate limits, payments, backups and monitoring, with a test for each item.
Published 2026-06-18.
AI coding tools are very good at making an app that works in the demo. They are less reliable at the parts nobody sees in the demo: who is allowed to read which data, what happens when input is hostile, and whether you can recover from a bad day.
This checklist covers those parts. Each item has a concrete test you can run in a few minutes. You do not need to be a security engineer to do it, and you can ask your coding agent to help with most fixes, as long as you check the result.
Before you start
Make two copies of your environment if you can: a development copy you can break, and production. Run the destructive tests (bad input, deleted rows, failed payments) against development. And keep a short list of everything you change, so you can explain it later.
The critical five: do these before anyone else uses the app
1. Secrets are not in the code or the repository
What to check: API keys, database passwords and tokens live in environment variables, not in source files, and .env files are not committed.
Test it:
# Is .env ignored?
git check-ignore .env && echo "ignored"
# Was a .env file ever committed?
git log --all --full-history -- '.env*'
# Any obvious keys in tracked files?
git grep -nE "sk_live_|sk_test_|SUPABASE_SERVICE_ROLE|BEGIN PRIVATE KEY"If a secret was ever committed, rotate it at the provider. Deleting the file does not remove it from history.
Also check the client bundle: anything prefixed for the browser (for example NEXT_PUBLIC_) is visible to every visitor. Service keys must never have that prefix.
2. Protected routes actually require login
What to check: every page and API route that shows private data checks that the user is signed in, on the server.
Test it: sign in, copy the URL of a private page, then open it in a private window. You should be sent to sign in. Repeat for API routes with a tool like curl, without your session cookie. A 200 response with data is a bug.
3. Users can only see their own data
What to check: the database or the API enforces ownership, not just the UI.
If you use Supabase, this means row level security (RLS) is enabled on every table that holds user data, with policies that limit rows to their owner. Supabase's dashboard flags tables without RLS.
Test it: create two test accounts. As user A, find the ID of one of A's records. As user B, request that record directly through the API. If B can read or change it, you have a data leak.
4. Input is validated on the server
What to check: every form and API endpoint validates input on the server, not only in the browser.
Test it: send a request directly to the API with missing fields, very long strings, wrong types and HTML or script tags. The server should reject it with a clear error, not save it or crash. A schema validation library such as Zod makes this straightforward; ask your agent to add schemas to every route that accepts input.
5. Backups exist and you have restored one
What to check: the database is backed up automatically, and you know how to restore it.
Test it: find your provider's backup settings and confirm the schedule and retention. Then restore a backup into a development database once. A backup you have never restored is a hope, not a backup.
Protecting users and the business
6. Rate limits on sensitive endpoints
Login, signup, password reset, contact forms and anything that calls a paid API (including AI model calls) need rate limits. Without them, one script can run up your bill or brute-force passwords.
Test it: send 50 quick requests to your login endpoint. Something should start refusing them.
7. Errors are friendly to users and detailed for you
Users should see a plain message; stack traces and database errors should go to your logs, not the screen.
Test it: break things on purpose. Submit a form offline, sign up with an existing email, pay with a declining test card. Look at what the user sees.
8. Payments work end to end, including failures
What to check: checkout, the webhook that grants access, the receipt, and what happens on failure or refund.
Test it in Stripe test mode with card 4242 4242 4242 4242 (succeeds) and 4000 0000 0000 0002 (declined). Confirm the webhook verifies its signature and updates your database. Our Stripe guide covers the details.
9. File uploads are restricted
If users can upload files, limit types and sizes on the server, store files outside your web root or in object storage, and never execute uploaded content.
10. Dependencies are audited
Run npm audit (or your package manager's equivalent) and fix high and critical issues. Remove packages the agent added but nothing uses; every dependency is code you are responsible for.
Reliability and visibility
11. Monitoring tells you when the app is down
Set up an uptime check on the homepage and on one critical route, such as login. Free tiers of uptime services are enough to start. You want to know before your users tell you.
12. Errors are logged somewhere you will read
console.log in a serverless function is not a logging strategy. Use an error tracking service such as Sentry1 or your host's log tooling, and check it during the first week after launch.
13. Migrations can be reversed
Coding agents write forward migrations readily and rarely write the rollback. Before running a migration that changes or deletes data on production, make sure you have a backup and a way to undo it, and run it on a copy first.
14. The app works on a phone
Shrink your browser to 375 pixels wide, or open the app on your phone. Check that nothing scrolls sideways, buttons are tappable and forms are usable. Many launch visitors arrive from social apps on mobile.
15. Basic accessibility
Images have alt text, text has enough contrast, and you can use the main flow with a keyboard. Free browser tools such as axe DevTools2 or Lighthouse find common problems quickly.
Legal basics and handover
16. Privacy policy and data deletion
If you collect emails, run analytics or store user data, you need a privacy policy that matches what you actually collect, and a way to delete a user's data on request. Requirements vary by country; GDPR, for example, can apply to you if you have users in the EU, even if you are elsewhere. This is not legal advice; check what applies to you.
17. A README future you can follow
Write down how to run the app locally, which environment variables it needs (names only, never values), how to deploy, and where backups and logs live. If a co-founder, contractor or future you cannot get it running from the README, it is not done.
What counts as good enough to launch
You do not need a perfect score to launch. You do need the critical five: secrets, protected routes, data ownership, server-side validation and backups. Those protect your users. Items 6 to 10 protect your business and your bill. Items 11 to 17 protect your ability to keep running it.
A useful prompt for your agent once you have run the tests:
Here are the results of my pre-launch security checklist: [paste].
For each failed item, propose the smallest change that fixes it, list the
files you would touch, and explain how I can verify the fix. Do not make
changes yet. Start with items 1 to 5.After the app is safe, check the page
A secure app with a page that does not explain it will still launch to silence. Once the checklist above is done, run the product launch checklist on your public page, or paste your URL at launchbuddy.ai/scan for a free launch-readiness score and the one gap to fix first.
Related reading
- Vibe debugging: how to fix AI-generated code you do not fully understand
- How to add Stripe payments to a vibe-coded app
- Lovable vs Bolt vs Cursor vs Replit
Sources and notes
Security Headers, Secrets, and the Public Launch Surface
A practical workflow to reduce obvious exposure before promoting a new domain. Keep observed behavior separate from a planned check; the checklist is a decision aid, not a guarantee of security, uptime, ranking or demand.
Five-step workflow
- 1. Inventory public routes and third-party scripts. Record an owner, date and evidence link for this step.
- 2. Remove secrets and debug output from client bundles. Record an owner, date and evidence link for this step.
- 3. Set proportionate browser security headers. Record an owner, date and evidence link for this step.
- 4. Test authentication and authorization boundaries. Record an owner, date and evidence link for this step.
- 5. Create a disclosure and response path. Record an owner, date and evidence link for this step.
Do the steps in order the first time. If a safety, privacy, financial, health, legal, or authorization boundary appears, pause the workflow. More activity is not progress when the prerequisite is missing.
Worked example
A prelaunch scan finds an old API key in a source map and an admin route that trusts client-side hiding. The key is rotated, the route is protected server-side, and regression checks are added before traffic is invited.
The useful pattern is the visible chain from context to evidence to decision. Another person should be able to understand what was observed, what remained uncertain, and why the next action was proportionate.
Keep a completion record
For each step, record the current behavior, the change you made, the result in production, what remains unknown, and the next owner. Repeat the original task after a change. Do not count a configured script or a visible form as delivery evidence.
Primary references
Continue with the LaunchBuddy tools or free launch scan if a public-site diagnostic would help.
- Sentry: https://sentry.io/
- axe DevTools: https://www.deque.com/axe/