Migrate Content Between Stacks Using the CLI
This document guides you through the process of migrating content from one Contentstack stack to another manually.
Prerequisites
- Contentstack account
- Contentstack CLI installed and configured
- CLI authenticated
- Access to both source and target stacks
- An empty target stack
Steps for Execution
To migrate all content from one stack to another quickly, follow the steps below:
- Export from source stack:
csdx cm:stacks:export -k <source_stack_api_key> -d ./export --branch main
- Audit the exported content (recommended):
csdx cm:stacks:audit -d ./export/main
Note: The audit process runs automatically during import to validate and fix any issues.
- Import to target stack:
csdx cm:stacks:import -k <target_stack_api_key> -d ./export/main
More articles in "Contentstack CLI Core Commands"
Export Content Using the CLI
Learn more
Import Content Using the CLI
Learn more
CLI-Supported Features for Export, Import, and Clone Operations
Learn more
Overwrite Existing Content using CLI Import
Learn more
Cloning a Stack
Learn more
Bulk Publish and Unpublish Content
Learn more
CLI for Launch
Learn more
Compare and Merge Branches Using the CLI
Learn more
Configure Early Access in the CLI
Learn more
Configure Rate Limits in the CLI
Learn more
Configure CLI Logging Preferences
Learn more
Audit Plugin
Learn more
Query-based Export
Learn more
