18 November 2026
٢٧ فحص أمان لموقعك قبل الإطلاق: خلّ Claude Code يمر عليها ويعطيك تقرير27 Security Checks Before You Launch Your Site: Let Claude Code Run Them and Report Back
Built your site with vibe coding and it works? This guide gives you 27 security checks in six groups, with a ready prompt for each, so Claude Code can audit, fix and report back before you share the link.
Who this guide is for
Anyone who built a website or web app with AI help and is about to launch it
Key terms
- vibe coding
- Building a site by talking to AI instead of writing the code yourself. Fast, but security is not added unless you ask for it.
- API key
- A password between your site and another service like payments or AI. If it leaks, anyone can use it on your account.
- RLS (Row Level Security)
- A rule inside the database that decides who can read or change each row. In Supabase the public key lives in the browser, so without RLS the table is open.
- security headers
- Lines the server sends with every page telling the browser how to protect the visitor, such as forcing HTTPS and blocking unknown scripts.
- CSRF
- An attack that makes a user's browser send a request to your site from another site without them knowing. You stop it with a per form token or cookie settings.
The steps
Step 1
Start on a safe copy
Work on a copy or a new Git branch, not on the live site. Open Claude Code inside the project folder.
The prompt below gives Claude the full picture: it reads the project first, orders the checks, and changes nothing until it shows you the plan.
Before I launch this site, I want a full security review across 27 checks in six groups. Read the project first and tell me: the framework, the database, how login works, and where the site is hosted. Then write the check plan in order, and do not edit any file until I approve the plan.PromptKickoff promptTip: Turn on plan mode in Claude Code so it plans before it edits.
Step 2
Group one: keys and secrets (5 checks)
The most dangerous mistake in fast built sites is a secret key inside browser code or inside Git.
Deleting the key from the code is not enough. It stays in Git history and in any clone or fork. The first fix is always to revoke the key in the service's dashboard and issue a new one.
Check the project on these five and report each result: 1. Is any secret API key in code that reaches the browser? Move it to the server. 2. Is .env in .gitignore and never pushed to Git? 3. Are any files publicly exposed, such as backups, .sql files or config files? 4. Search the full Git history for any key or password committed at any point. 5. For any exposed key: list the services where I must revoke and reissue keys, and update the code to read keys from environment variables.PromptSecrets checkStep 3
Group two: login and accounts (5 checks)
Login written from scratch usually has holes. The safer path is a known auth service such as Supabase Auth or a similar provider.
Passwords are never stored as text. They are stored as a hash with an algorithm made for passwords.
Check login and accounts: 1. Is login built on a known service or library? If it is hand written, suggest the replacement. 2. Are passwords stored as a hash with an algorithm like bcrypt or Argon2? 3. Do password reset links expire quickly and work only once? 4. Do session cookies have HttpOnly, Secure and SameSite? 5. Do admin pages require login and check the user's role on the server, not just hide the button?PromptAuth checkStep 4
Group three: database and visitor input (5 checks)
The rule is simple: trust nothing that comes from the browser. Front end validation is for convenience. Real validation happens on the server.
If you use Supabase, enable RLS on every table in the public schema and give each table a policy.
Check the database and inputs: 1. Is RLS enabled on every table, with a clear policy for each? List any table without it. 2. Does every form validate input on the server, not only in the browser? 3. Do all queries use parameterized queries instead of string concatenation? 4. Is any visitor text rendered as text, not as HTML, so there is no XSS? 5. Are uploads limited by type and size, and checked on the server?PromptData and input checkTip: Ask Claude to write the RLS policies and explain each one before it runs them.
Step 5
Group four: server and requests (5 checks)
These settings protect the site even when the code itself is clean. Most hosting platforms let you add them in one config file.
After the change, confirm the headers with curl -I on your site's address.
Check the server settings: 1. Is HTTPS forced, with every http request redirected to https? 2. Is there rate limiting on the login page and the API endpoints? 3. Does CORS allow only my site's domain, not any origin? 4. Add security headers: Content-Security-Policy, Strict-Transport-Security, X-Content-Type-Options, and X-Frame-Options or frame-ancestors. 5. Are debug mode and detailed error messages off in production?PromptServer checkStep 6
Group five: money and monitoring (4 checks)
If your site sells, the price is calculated on the server from the database. Any price that comes from the browser can be edited.
Old libraries are an open door you cannot see, so update them and remove the ones you do not use.
Check payments, monitoring and libraries: 1. Are price and quantity verified on the server before payment, never taken from a browser value? 2. Are failed logins and unusual activity logged and watched? Suggest the simplest setup. 3. Run a dependency vulnerability scan (such as npm audit) and update anything with known vulnerabilities. 4. Remove libraries the project does not use.PromptPayments and monitoring checkStep 7
Last group: CSRF, full review and the report (3 checks)
The last step pulls it together: CSRF protection on forms, a full security review of the code, and a real test of the protections.
The report is what you keep: every issue, where it was, and how it was fixed.
1. Make sure every form that changes data is protected against CSRF. 2. Do a full security review of the code and focus on anything the earlier checks did not cover. 3. Test the protections we added and give me a report as a table: check, result, issue, file, and how it was fixed. End with a list of things I must do myself, such as rotating keys.PromptReview and reportStep 8
Approve every change and test before you ship
Do not accept all changes at once. Read each change and test the site on the copy: log in, order something, upload a file.
If your site takes payments or holds customer data, the Claude review is a strong start, but have a security professional review it before launch.
Tip: Save the report in the project and revisit it before every big update.
Ready prompts to copy
The takeaway
A site that works is not a site that is safe. Give Claude the list, approve every change, and keep the report.
Liked this guide?
Join Mohammad's community
72 guides like this one, and a new one every week. One subscription opens them all.
Approximate price in your currency. You pay in AED
- A permanent archive. Open any guide, any time
- 20% off private build sessions
- Cancel any time, no commitment
Or without a subscription
Most value
Start building with me now
We sit together, break down your problem, and I build the AI solution with you step by step
- A private session with you
- Real building during the session
- Results you take with you when we finish
100% free
A free consultation about your problem
