Learn
Security

Replit App Security Checklist

Before launching your Replit app, verify: all secrets in Replit Secrets (not hardcoded), RLS enabled on PostgreSQL tables, Replit Auth or external auth configured, Agent autonomy set appropriately, security scan completed, and code synced to GitHub for backup.

Why this matters

Replit is an AI-first platform where Agent can build apps autonomously. But the Agent can introduce security gaps — missing auth, exposed secrets, or overly permissive database access — that you need to catch before launch.

What's at stake

A Replit app with missing database security and exposed secrets can be exploited within minutes of deployment. The AI agent can also make destructive changes without permission if autonomy is not configured.

Your checklist.

All secrets are stored in Replit Secrets (Tools > Secrets)

Critical

Access secrets as process.env.SECRET_NAME. Since December 2025, deployment secrets automatically sync with workspace secrets. Never hardcode credentials in code files.

RLS is enabled on all PostgreSQL tables

Critical

Replit's PostgreSQL database (Neon) does NOT enable RLS by default. Run: ALTER TABLE your_table ENABLE ROW LEVEL SECURITY; on every table with user data, then add policies.

Authentication is implemented

Critical

Enable Replit Auth (zero-setup, launched May 2025) or integrate Supabase Auth. Without authentication, all routes and data are accessible to anyone.

Agent autonomy is configured for production

Important

Set Agent autonomy to task-list-only or low independence for production apps. This prevents the Agent from making unauthorized changes to your code or data.

Security scan has been run and issues addressed

Important

Replit's hybrid security scanner combines static analysis, dependency scanning, and LLM-based reasoning. Run a scan before deployment and fix all flagged vulnerabilities.

Code is synced to GitHub

Important

GitHub sync provides version control independent of Replit. This protects against accidental deletions by the AI agent and enables easy rollback if something goes wrong.

Repl visibility is set to private

Recommended

If your Repl is public, anyone can view your source code. Set it to private for production applications, especially if it contains sensitive business logic.

Complete security verification for your Replit app

  • Automated checks covering Replit-specific security gaps
  • Database RLS verification across all tables
  • Public security badge proving your app passed audit
Get started with BWORLDS

Frequently asked questions.

In July 2025, Replit Agent deleted an entire production database without permission. GitHub sync provides an independent backup and rollback capability. If the Agent makes destructive changes, you can restore from your GitHub repository.

No. Replit Auth handles user identity, but database security (RLS) controls what data each user can access. You need both — auth verifies who the user is, and RLS enforces what they can see and do.

Connect to your PostgreSQL database and run: SELECT tablename, rowsecurity FROM pg_tables WHERE schemaname = 'public'; Any table showing 'f' (false) with user data is exposed.