Skip to main content

Version history & undo

You don't have to remember to save. Every AI change that actually touches your files is saved as a version automatically, with a short summary of what changed — so you can look back, undo the last thing, or go all the way back to an earlier state of the app.

Nothing here is public

Restoring changes your project's files and the live lane of the live preview, not what your visitors see. Your public site only changes when you publish.

Open the project first​

Versions are read from your project's running preview. Open the project and wait for the preview to start — if there's no running session, the history list comes back empty and restoring fails with "No active preview session — open the project first."

Browsing versions​

Above the live preview there's a history control. It lists your versions newest-first, and for each one shows:

  • The change summary — the first line of the plan the AI wrote for that build, shortened to fit.
  • How long ago it was made.
  • A short commit ID, which is what you'd match against commits in your own repository if you use GitHub sync.

The version you're currently looking at is marked in the list. The list shows your most recent versions — currently the last 50 — rather than the entire life of the project.

For a longer write-up of a change than the one-line summary, the AI also saves a note into the project itself, under .berrybell/history/. The .gitignore that current templates and new blank projects come with excludes that folder, so the notes aren't saved as part of a version and GitHub sync doesn't send them to your repository. An older project's .gitignore may not list it, and then the notes are committed and pushed like any other file — see What isn't pushed. The notes are stored with the rest of your files, so a ZIP download of the project does include them.

Restoring a version​

Pick a version from the list and the project goes back to it.

Restoring is additive. It creates a new version rather than erasing the ones after it — so the state you just left is still in the list, and you can restore forward again if you change your mind. There's no way to lose work by looking around.

A few things to expect:

  • If another operation is already running on the project, a restore can fail with PROJECT_BUSY. Wait a moment and try again.
  • A restore changes your project's files and the live dev session straight away, but it doesn't rebuild the built copy the preview pane shows by default. That copy stays on the pre-restore build until the AI's next change. To see the restored version now, choose the select element tool to switch to the live lane (see The built lane and the live lane).
  • A restore never touches your published site. If you want the public URL to match what you just restored, publish again.

Undoing the last AI change​

There's also a one-click undo for the most recent change, which is the fastest way out of a build that went sideways.

Undo is unavailable when:

  • A build is currently running.
  • You just restored or undid something — undo comes back once the AI makes the next change.
  • There is only the starting version and so nothing to undo to.

What versions do and don't cover​

Versions track code changes to your project. They do not:

  • Roll back your database. Restoring an earlier version of the code won't put back rows that were changed or deleted, and it doesn't undo schema changes either. When the AI adds a table or column, it records the change as a file under migrations/. Restoring a version from before that change removes the file from your code, but the table or column stays in the database. To reverse a schema change, ask the AI for a new change that undoes it. If the change reached production and you took a backup before it, you can restore that instead. Nothing takes a backup automatically before a schema change, and backups are of production only: restoring one replaces your live app's data straight away, so anything written since is lost. On another environment, reset it from production instead, which discards data and schema changes made only there.
  • Un-publish a live site. A restore is a change to your working project; republish if you want the public app to match.

If you want the full commit-by-commit history in a repository you control — including branches, diffs and your own tooling — connect GitHub sync.

Next steps​