Skip to content

Rollbacks

You can roll back to a previously deployed version of your Worker using Wrangler or the Cloudflare dashboard. Rolling back to a previous version of your Worker will immediately create a new deployment with the version specified and become the active deployment across all your deployed routes and domains.

You can roll back from any deployment, including:

  • A single-version deployment (rolling back replaces the current version with the selected version).
  • A split deployment with two versions (rolling back replaces both versions with the selected version at 100% traffic).

Via Wrangler

To roll back to a specified version of your Worker via Wrangler, use the wrangler rollback command.

Via the Cloudflare Dashboard

To roll back to a specified version of your Worker via the Cloudflare dashboard:

  1. In the Cloudflare dashboard, go to the Workers & Pages page.

    Go to Workers & Pages
  2. Select your Worker > Deployments.

  3. Select the three dot icon on the right of the version you would like to roll back to and select Rollback.

Rolling back from a split deployment

If you are using a gradual deployment with two versions splitting traffic, rolling back will:

  1. Replace the split deployment with a single-version deployment.
  2. Route 100% of traffic to the version you selected for rollback.

This effectively promotes one version to handle all traffic, which is useful if you notice issues with one of the versions in your split deployment and want to revert to a stable version immediately.

To roll back from a split deployment:

  1. Identify which version in your split deployment is stable and performing correctly.
  2. Use the rollback procedure or dashboard rollback to roll back to that version.
  3. The split deployment will be replaced with the selected version at 100% traffic.

Limits

Rollbacks limit

You can only roll back to the 100 most recently published versions.

Bindings

You cannot roll back to a previous version of your Worker if the Cloudflare Developer Platform resources (such as KV and D1) have been deleted or modified between the version selected to roll back to and the version in the active deployment. Specifically, rollbacks will not be allowed if:

  • A Durable Object migration has occurred between the version in the active deployment and the version selected to roll back to.
  • If the target deployment has a binding to an R2 bucket, KV namespace, or queue that no longer exists.