In this article you'll learn:
Bring data from existing MongoDB deployments, JSON
, or CSV
files into deployments in Atlas using either:
Live migration where Atlas assists you, or
Tools for a self-guided migration of data from your existing deployments into Atlas
Which migration option is right for you?
Live Migration
Cannot afford a lot of downtime
Dedicated cluster (M10 and above)
Self-Guided
You have a small dataset
The cluster you are migrating is on a shared tier (M0/M2/M5) or a serverless cluster
You have a large dataset that can have more downtime
Live Migrate doesn’t support your configuration
Tools for Migrating to Atlas based on Cluster Configuration
Choose between different tools for data migration and import for common cluster configurations:
Source Cluster Configuration | Import Strategy |
MongoDB deployment that is managed by Cloud Manager or Ops Manager | Use live migration (push) where Cloud Manager or Ops Manager pushes data to Atlas using a secure link token without requiring access to the source cluster through the cluster's firewall |
MongoDB deployment that is not managed by Cloud Manager or Ops Manager | Use live migration (pull) where Atlas pulls data from the source deployment and requires access to the source deployment through the deployment's firewall |
Shared multi-tenant cluster
Cluster where you have no access to the oplog
Cluster that runs a MongoDB version that is no longer supported | Use mongodump and mongorestore to seed a MongoDB Atlas cluster with data from an existing MongoDB standalone or replica set |
Standard "single shard" sharded cluster MongoDB deployment in Compose | Live Migration for Compose to MongoDB Atlas |
Migrate a MongoDB Replica Set from AWS to MongoDB Atlas | Live Migration for AWS to MongoDB Atlas |
For a guided minimal-downtime migration procedure, see Replica Set Live Migration or Sharded Cluster Live Migration.
Self-Managed Migration Tools
Self-managed tools (also known as backup-and-restore) are great options if:
You have a small dataset
The cluster you are migrating is on a shared tier (M0/M2/M5) or a serverless cluster
You have a large dataset that can have more downtime
Note: These are the only options available for shared cluster migrations.
Tool | Description |
Seed an Atlas cluster with a | |
Load data from a | |
Use a GUI to load data from a | |
Migrate your sharded cluster or a replica set into an Atlas cluster with minimal downtime. Mongosync supports heterogeneous migrations (e.g. from a replica set to sharded cluster, or from N shards to M shards), as well as many other features.
Supports MongoDB versions 6.0+ |
You can also restore from an Atlas cluster backup data to another Atlas cluster. For information, see Restore Your Database Deployment.
Additional Resources
If you cannot afford a lot of downtime and are migrating a dedicated cluster (M10 and above), Live Migrate is the best option for your application.
To move data to a serverless instance, use Compass to export and import data, or migrate data with self-managed tools. To learn more, see Serverless Instance Limitations.
To load data into a new cluster in Atlas, see Load Sample Data.
To make a copy of your cluster for testing purposes, see MongoDB Backup Methods.
If the application that you want to migrate requires a near-continuous uptime, contact MongoDB Support and share your uptime requirements and cluster configuration.