Partly fixable yourself. Rollback and restore are in Replit's UI; lost data needs care.
- How serious
- High
- Fix it yourself?
- Partly, some steps need a developer
- Typical cost
- $49–$800 check, $1,500–$15,000 for a cleanup (prices)
- Top rated for Replit
- Afterbuild Labs · 10.0/10
Press Stop, do not send more messages, and roll back to the checkpoint before the trouble started. Checkpoints restore code and, if you tick the Database option, the development database. Production data is separate: it is restored from point-in-time history in the Database tool, and the Agent cannot touch it on current Replit apps.
What you see, and what it usually means
| What you see | What it usually means |
|---|---|
| The Agent repeats the same change and the error never goes away. | It has lost the thread of the task. Stop it and start a new chat with one goal. |
| Tables or rows in your development database vanished after a session. | The Agent reset or migrated the dev database. A rollback with Database ticked brings it back. |
| Real users' data is gone from the published app. | Production needs a point-in-time restore, not a checkpoint rollback. |
| Rolling back fixed the code but not the data, or the other way round. | Code and database are restored separately on Replit. |
| Your bill jumped during the loop. | Each Agent message is billed. Set a usage limit so a loop cannot run up a large bill. |
Why it happens
Replit saves checkpoints as the Agent works. A checkpoint is a snapshot of files, chat context, configuration and database contents, and a rollback returns the project to that point. By default the rollback leaves the development database alone, so you must select Database under Additional rollback options to bring data back. Production databases are excluded from rollbacks on purpose.
Production has its own recovery. Every plan starts with 7 days of point-in-time history, and Pro and Enterprise can extend it to 28 days. Scheduled backups add one restore point per day. Replit's docs put it plainly: restoring your database does not restore your app's code, and rolling back your app does not restore your database. After the July 2025 incident in which the Agent wiped a founder's live database, Replit's CEO called it unacceptable and rolled out automatic separation of development and production databases. On current apps the Agent cannot modify production, so the same mistake today mostly costs test data.
Check these first
Database backups run automatically and a restore has been tested
Check what your database plan actually includes, then restore a backup into a test project once.
Testing and real users use separate databases
Experiments and AI agents should never run against production data.
The code lives in a Git repository you own
Connect GitHub or export the project. If the builder account is lost, the product should not be.
Errors reach you before users do
Add error monitoring and uptime alerts. If you learn about outages from customers, this is missing.
AI and paid API calls have per-user limits
Without a cap, one user or one bot loop can spend your monthly budget in an hour.
Fix it yourself
- Click Stop in the Agent panel. If it looks frozen, do not send another message. Replit's help page says extra messages create conflicting instructions. If needed, press Cmd+K or Ctrl+K, search "Restart compute", and open a new chat.
- In the Agent chat, find the message just before the bad change and choose the rollback option. Tick Database under Additional rollback options if development data is missing too.
- For lost production data, open the Database tool, select the production database, and restore from point-in-time history. You type
restoreto confirm. The restore does not delete current data. - Then roll the code back to the matching checkpoint and republish. Do both or the app and its data will not match.
- In the production database Settings, expand Scheduled backups under Advanced and choose a retention period. Longer windows raise storage cost, and retention is capped at 7 days on Core and 28 on Pro.
- Set a usage limit in your account and switch to Plan mode for anything larger than one small change. Give the Agent the exact error text and the file name, not a repeat of the same request.
- Push the code to GitHub so your work does not depend on one Replit account.
When to get a human engineer
Get an engineer when production data is gone and you are not sure which restore point is clean, or when the Agent has rewritten your database schema more than once and nothing lines up. A one-off check at $49 to $800 over a day to a week will tell you what can still be recovered. Recovering data and matching it to the right code is a single fix in the €99 to $990 band, about two days. If you want someone to keep backups tested and watch errors, ongoing care runs $100 to $5,000 a month. Our Replit guide covers the separation checks.
Top-rated companies for Replit apps
Ranked by our score: published prices, scope of work, AI tools named, timing and a low-risk first step. How we score.
- 1Afterbuild Labs10.0/10Best for: A check before launchFree first step · from $49
- 2Redlab10.0/10Best for: A full rescue by one team that keeps buildingFree first step · from $490
- 3Vibe Code Rescue (Lev Arakelyan)9.0/10Best for: A one-off check and a cleanupFrom $299
Questions
Can Replit recover data the Agent deleted?
Development data: yes, through a checkpoint rollback with Database ticked, up to 7 days back. Production data: yes, through point-in-time restore or a scheduled backup inside the retention window. Removed databases stay recoverable for 7 days.
Does rolling back cost anything or lose my newer work?
A rollback discards every change made after the chosen checkpoint. You can roll forward to a later checkpoint only until you make new changes, which start a new branch of history.
Can the Replit Agent still delete my live database?
On current Replit apps the Agent cannot modify the production database. It can still change the development database, and schema changes it makes there are applied to production when you publish, so review them before publishing.
Sources: Replit docs: Checkpoints and rollbacks; Replit docs: Data recovery; Replit docs: Production databases; Replit help: Agent and AI (stuck, loops, usage limits); The Register, 22 Jul 2025: Replit response to the SaaStr database deletion.
