Pre-publish security scan
Runs before every publish, and can block publishing when it finds critical vulnerabilities.
Replit scans your project before every publish. These are the checks that still need your attention.
Sound familiar?
Replit scans for vulnerabilities before every publish; turn on blocking for critical findings. Keep keys in Secrets, check the published app’s secrets yourself because Replit’s docs disagree on whether they carry over, regenerate any leaked database credentials, and check access in every route.
Why it happens
Replit always runs a security scan before publishing, and a setting can block publishing when critical vulnerabilities are found. Security Agent combines AI with static analysis tools. But scanners read your code; they don’t know your business rules.
Most real risk sits in how secrets are handled (keys belong in Secrets, not code), the production database credentials, and access checks in your own backend routes.
Already done for you
Runs before every publish, and can block publishing when it finds critical vulnerabilities.
Encrypted values your app reads as environment variables. Not available on Static Deployments.
The development DATABASE_URL works only for your app, and production credentials can be regenerated if they leak.
When Agent adds a database, it adds an ORM with schema validation and input sanitising against SQL injection.
Fix it yourself
In this order. Most apps get most of the way with these alone.
In Publishing, run the security scan, fix critical findings, and turn on blocking for critical vulnerabilities.
Search the code for keys. Anything committed or pasted somewhere shared should be rotated with the provider.
Replit’s docs disagree on whether editor secrets carry over to the published app, so open Publishing → Adjust settings and confirm production values, such as live keys, are there.
If a production connection string was exposed, regenerate it in the Database tool. Old strings stop working immediately.
Replit Auth uses Replit accounts and a Replit-branded page. Clerk Auth gives your app its own accounts and branding, with separate development and production environments.
Every route that returns or changes user data should check the signed-in user, not just hide buttons in the interface.
If the steps above turn up more than you have time for, or the app already has paying users, I take Replit apps to production: login and access rules, database and backups, payments, security, SEO and deployment.
App rescue: From $1,000, fixed price, scoped in writing before any work starts.
More in app rescue, or hire a Replit developer.
Questions
Yes. It always runs a security scan before publishing, and you can block publishing when critical vulnerabilities are found.
In Secrets, which are encrypted and exposed to your app as environment variables. Static Deployments don’t support Secrets.
Replit’s docs suggest Replit Auth for prototypes and internal tools, and Clerk Auth for branded, customer-facing or commercial products.
Regenerate the production database credentials in the Database tool. Existing connection strings stop working immediately, so update any tools that used them.
Send me the app and what’s worrying you. You get a written scope with a fixed price before any work starts.