Skip to content

schema rollback

Loads a changeset written by a previous schema push and reverts the Storyblok space to the state captured before that push. If no changeset-file is passed, the command lists available changesets and prompts for one, unless --latest selects the most recent automatically.

Applying a rollback writes a new changeset capturing the rollback operation itself, so the rollback itself can be reverted.

  • A changeset file generated by a previous schema push is required to perform the rollback.
Terminal window
storyblok schema rollback [changeset-file] [flags]
Argument Type Description
Changeset file string Optional. Path to the changeset file to roll back to. Omit and pass --latest to auto-pick.
Flag Type Description
--space, -s integer Required. The ID of the Storyblok space to roll back.
--path, -p string Optional. Base path where changesets are stored.
--dry-run boolean Optional. Show what would be undone without applying changes.
--yes boolean Optional. Skip the interactive confirmation prompt.
--latest boolean Optional. Automatically select the most recent changeset.

The following examples assume that a space has been defined in a configuration file.

Terminal window
# Roll back the most recent push
storyblok schema rollback --latest
# Roll back to a specific changeset
storyblok schema rollback .storyblok/schema/changesets/2026-05-11T10-00-00Z.json
# Preview the rollback without applying changes
storyblok schema rollback --latest --dry-run

Was this page helpful?

What went wrong?

This site uses reCAPTCHA and Google's Privacy Policy (opens in a new window).Terms of Service (opens in a new window) apply.