In Studio 3T, you can reliably (and easily) copy MongoDB documents and paste them across databases and collections.

Download our MongoDB GUI, and let’s get started.

Download Studio 3T
Get Download Link for Later

1. Open your source MongoDB collection in Studio 3T and select the documents that you would like to copy – either by selecting the documents themselves or any of their fields.

2. Right-click and choose “Copy Selected Documents To Clipboard” from the popup menu – or use the keyboard short-cut Shift+Cmd+C. (Note that just Cmd+C would copy the selected individual fields rather than the entire documents)

MongoChef for MongoDB: Copy documents to clipboard

3. Next, open your MongoDB target collection.

4. Right-click anywhere and select “Paste Documents” (or simply press Cmd+V), and the documents are copied into the target collection. Easy as that.

MongoChef for MongoDB: Paste documents from clipboard

And voilà:

MongoChef for MongoDB: Copy and paste documents

And the best is: Copy & paste in Studio 3T is 100% reliable and lossless! All types (including complex ones such as Code-with-Scope, Timestamp, or fine-grained ones such as Int32, Int64) are supported and preserved.

Studio 3T also pastes documents with their original _id. By default, if a duplicate document already exists, the to-be-pasted document will be inserted with a new ObjectId in its _id field. If you need more fine-grained control over how duplicate documents should be handled, you can do so via the import dialog.

MongoChef for MongoDB: Copy and paste documents with ObjectId

Choose “Clipboard” in the “From” combo box. On the right, you can choose what should happen if an existing _id is encountered. You can choose from 4 options (“Create new _id if it already exists”, ”Skip existing documents”, ”Always insert with new _id”, “Abort if _id already exists”).

Don’t forget to check out our What’s New section for other helpful tips on how to update field values, modify MongoDB indexes, handle special characters on MongoDB, and more. If you haven’t downloaded our MongoDB GUI yet, here you goHappy copy & pasting!