How to Run Rollback from a Branch
Rollback lets you restore a Salesforce org to its pre-deployment state. It creates a backup automatically, so if errors or unwanted changes occur, you can quickly return the org to stability.
What is Rollback
Rollback reverts metadata changes applied during a deployment.
It:
Uses the pre-deployment backup snapshot stored by Deployment.
Restores components to their original state.
Ensures stability after a failed or problematic deployment.
Rollback is essential for production environments where deployment errors must be corrected quickly.
Prerequisites
A completed deployment job with a backup created.
A branch with components available for rollback.
How to Run Rollback
Step 1: Open the deployment job
Navigate to Activities → Jobs in your branch.
Locate the completed deployment entry.
Open the job details page.
Step 2: Start rollback
Click the Rollback button at the top of the deployment results page.
The Rollback wizard opens.

Step 3: Select components
The Rollback page lists components that changed during the deployment.
Each component is marked as Changed.
Select the components you want to roll back, or click Add All to include everything.
Click Next / Run to proceed.

Step 4: Run rollback
Confirm your selection.
Click Run to start the rollback process.
The rollback job is queued and tracked in Activities → Jobs.

How to Check Rollback Status
Once started, the rollback job appears in the Jobs list.
Status values include: Queued, In Progress, Completed, Exception.
Filters (type, status, date range) help you quickly find rollback jobs.
How to View Rollback Results and Logs
From Activities → Jobs, click the rollback job entry.
The results page shows:
Connection used
Status, duration, start/end time
Who triggered the rollback
Logs on the right display details such as:
Project creation and backup retrieval
Metadata restoration steps
Number of rolled back components
Success or error messages

Best Practices
Always validate and test before deploying to minimize rollback needs.
Rollback all changed components if deployment caused major issues.
Use rollback quickly in Production to restore stability.
Review rollback logs to confirm every component was successfully reverted.
After rollback, re-validate the branch before redeploying.
Last updated
Was this helpful?
