Pre-Deployment Backups
Learn how HubSpot Deploy automatically protects your data by creating backups before every deployment. This safety feature enables quick rollback if something goes wrong.
Overview
Pre-deployment backups are automatic snapshots of your HubSpot configuration taken immediately before deploying changes. This safety net allows you to:
- Undo changes if deployment causes issues
- Restore previous state with one click
- Deploy confidently knowing you can rollback
- Maintain audit trail of what was changed
Key point: These backups happen automatically—you don't need to do anything. The system creates them before every deployment.
How It Works
Automatic Backup Process
When you deploy changes, the system:
- Identifies items to update: Only items being modified (not new items)
- Fetches current state: Reads current configuration from HubSpot
- Stores backup: Saves snapshot to secure storage
- Proceeds with deployment: Applies your changes
- Keeps backup available: Ready for rollback if needed
Example:
You're deploying: Update "Welcome Workflow"
↓
System fetches: Current version of "Welcome Workflow" from HubSpot
↓
System saves: Backup of current version
↓
System deploys: Your updated version
↓
Backup available: Can rollback to previous version anytime
What Gets Backed Up
Backed up automatically:
- ✅ Items being updated (status: "different")
- ✅ Current state from target portal
- ✅ All configuration details
Not backed up:
- ❌ Items being created (status: "new") - nothing to backup
- ❌ Items being deleted - handled separately
- ❌ Items with no changes (status: "identical")
Supported Metadata Types
Pre-deployment backups support most metadata types:
Fully Supported
| Metadata Type | Backup | Restore |
|---|---|---|
| Custom Objects | ✅ | ✅ |
| Standard Objects | ✅ | ✅ |
| Properties | ✅ | ✅ |
| Pipelines | ✅ | ✅ |
| Forms | ✅ | ✅ |
| Email Templates | ✅ | ✅ |
| CTAs | ✅ | ✅ |
| Campaigns | ✅ | ✅ |
Not Yet Supported
- Workflows (complex dependencies)
- Lists (dynamic membership)
- Landing Pages (content complexity)
- Site Pages (content complexity)
- Blog Posts (content complexity)
Note: For unsupported types, use Metadata Backups to Git before deploying.
Viewing Backup Status
During Deployment
Watch the deployment progress to see backup status:
Deployment log example:
✅ Backing up items...
✅ Welcome Workflow (backed up)
✅ Contact Form (backed up)
⏭️ New Campaign (skipped - new item)
✅ Deploying changes...
✅ Welcome Workflow (deployed)
✅ Contact Form (deployed)
✅ New Campaign (deployed)
After Deployment
Check deployment history to see backup details:
- Navigate to Comparisons
- Open your comparison
- Click History tab
- View deployment record
- See backup count in details
Backup summary:
- Backed up: 2 items
- Skipped: 1 item (new)
- Failed: 0 items
Rolling Back Deployments
If a deployment causes issues, you can rollback to the previous state.
When to Rollback
Common scenarios:
- Deployment broke a workflow
- Form stopped working correctly
- Property changes caused issues
- Need to undo recent changes quickly
How to Rollback
Option 1: Via UI (Coming Soon)
- Navigate to Deployment History
- Find the deployment to undo
- Click Rollback
- Confirm rollback
- Wait for restoration to complete
Option 2: Via Support (Current)
- Note the deployment ID
- Contact support
- Request rollback
- Support team will restore backups
Rollback Process
When you rollback:
- Fetches backups: Retrieves all backups for that deployment
- Orders by dependencies: Restores in reverse dependency order
- Restores each item: Applies backed-up configuration
- Reports results: Shows what was restored and any errors
Example:
Rolling back deployment #12345...
✅ Restored: Contact Form
✅ Restored: Welcome Workflow
✅ Restored: Custom Property "lead_score"
Rollback complete: 3 items restored, 0 errors
Rollback Limitations
What rollback does:
- ✅ Restores configuration to previous state
- ✅ Undoes property changes
- ✅ Reverts workflow modifications
- ✅ Restores form settings
What rollback doesn't do:
- ❌ Restore deleted items (use separate restore process)
- ❌ Undo data changes (CRM records)
- ❌ Reverse workflow executions
- ❌ Restore historical data
Backup Storage
Where Backups Are Stored
Backups are stored securely in the system database:
- Encrypted at rest: All backup data is encrypted
- Workspace-scoped: Only accessible within your workspace
- Linked to deployment: Associated with specific deployment record
How Long Backups Are Kept
Retention policy:
- Active deployments: Backups kept indefinitely
- Old deployments: Backups retained for 90 days
- Deleted comparisons: Backups deleted with comparison
Best practice: Keep important comparisons to preserve backup history.
Backup Size
Backups are lightweight:
- Only configuration data (not CRM records)
- Compressed JSON format
- Typical size: 1-10 KB per item
Example sizes:
- Workflow: ~5 KB
- Form: ~3 KB
- Property: ~1 KB
- Pipeline: ~2 KB
Best Practices
Before Deploying
1. Review what will be backed up:
- Check deployment preview
- Verify items marked as "different"
- Understand what will change
2. Test in staging first:
- Deploy to staging portal
- Verify changes work correctly
- Then deploy to production
3. Deploy during low-traffic times:
- Reduces impact if rollback needed
- Easier to test after deployment
- Less disruption to users
After Deploying
1. Verify changes immediately:
- Test affected workflows
- Check forms still work
- Verify properties display correctly
2. Monitor for issues:
- Watch for error notifications
- Check workflow execution logs
- Review form submissions
3. Keep deployment history:
- Don't delete comparisons immediately
- Preserve backup history
- Maintain audit trail
Rollback Strategy
1. Act quickly:
- Rollback as soon as issues detected
- Don't wait for problems to escalate
- Better safe than sorry
2. Document issues:
- Note what went wrong
- Screenshot error messages
- Record steps to reproduce
3. Investigate before re-deploying:
- Understand why deployment failed
- Fix underlying issues
- Test thoroughly before trying again
Common Scenarios
Scenario 1: Workflow Update Gone Wrong
Problem: Updated workflow is sending emails to wrong contacts
Solution:
- Immediately pause the workflow in HubSpot
- Request rollback of deployment
- Workflow restored to previous version
- Review and fix workflow logic
- Test in staging before re-deploying
Scenario 2: Form Changes Break Submission
Problem: Form changes prevent submissions from working
Solution:
- Note the deployment ID
- Request rollback
- Form restored to working state
- Investigate what caused the issue
- Fix and test before re-deploying
Scenario 3: Property Update Causes Display Issues
Problem: Property changes break portal views
Solution:
- Rollback deployment immediately
- Properties restored to previous state
- Views work correctly again
- Review property dependencies
- Update carefully and test
Troubleshooting
Backup Failed During Deployment
Problem: Deployment log shows "Backup failed"
Possible causes:
- Item doesn't exist in target portal (404)
- Connection expired
- Insufficient permissions
Solution:
- Check deployment logs for specific error
- Verify connection is active
- Ensure you have required scopes
- Retry deployment
Note: Deployment continues even if backup fails, but rollback won't be available for that item.
Cannot Rollback Deployment
Problem: Rollback option not available
Possible causes:
- No backups were created (all items were new)
- Backups expired (>90 days old)
- Comparison was deleted
Solution:
- Check if any items were backed up
- Verify deployment is recent (up to 90 days)
- Manually restore from Git backup if available
Rollback Partially Failed
Problem: Some items restored, others failed
Possible causes:
- Dependencies changed since backup
- Items deleted manually
- Permission changes
Solution:
- Review rollback report for errors
- Manually fix failed items
- Check dependencies
- Contact support if needed
Backup Taking Too Long
Problem: Deployment stuck on "Backing up items"
Factors:
- Number of items to backup
- HubSpot API response time
- Network latency
Expected times:
- Small deployment (less than 10 items): 10-30 seconds
- Medium deployment (10-50 items): 30-90 seconds
- Large deployment (more than 50 items): 1-3 minutes
Solution: Wait patiently. If stuck more than 5 minutes, contact support.
Security & Compliance
Data Protection
Encryption:
- Backups encrypted at rest
- Secure transmission (TLS 1.2+)
- Access controlled by workspace permissions
Access Control:
- Only workspace members can view backups
- Rollback requires deployment permissions
- Audit trail of all backup operations
Compliance
Audit Trail:
- All backups logged
- Rollback operations tracked
- Deployment history preserved
Data Retention:
- Backups kept for 90 days
- Automatic cleanup of old backups
- Manual deletion with comparison
Comparison with Other Backup Types
| Feature | Pre-Deployment Backups | Metadata Backups | Data Backups |
|---|---|---|---|
| When | Automatic before deploy | Scheduled or manual | Scheduled or manual |
| What | Items being updated | All portal configuration | CRM records |
| Format | JSON in database | JSON/YAML in Git | CSV files |
| Purpose | Quick rollback | Version control | Data recovery |
| Retention | 90 days | Forever (in Git) | 90 days |
| Restore | One-click rollback | Deploy from Git | Manual import |
Use together:
- Pre-deployment backups: Safety net for deployments
- Metadata backups: Long-term version control
- Data backups: CRM data protection
Related Features
- Deployments: Learn about deployment process
- Deployment History: View past deployments
- Metadata Backups: Long-term backup to Git
- Assisted Deployment: Step-by-step deployment control
FAQ
Are backups created for every deployment?
Yes, backups are created automatically for all items being updated. New items don't need backups since they don't exist yet.
How long are backups kept?
Backups are kept for 90 days. After that, they're automatically deleted to save storage space.
Can I disable pre-deployment backups?
No, backups are a core safety feature and cannot be disabled. They ensure you can always rollback if needed.
Do backups slow down deployments?
Slightly. Backups add 10-30 seconds to deployment time, but this is a small price for the safety they provide.
What if backup fails?
Deployment continues, but you won't be able to rollback that specific item. The deployment log will show which items failed to backup.
Can I manually create a backup before deploying?
Yes, use Metadata Backups to create a full backup to Git before deploying. This provides an additional safety layer.
Next Steps
- Learn about deployment process
- Set up metadata backups to Git
- Review deployment history
- Understand assisted deployment