Compass and Tools

Compass and the MongoDB Database Tools

Compass 1,815 is MongoDB 1,815 's free desktop GUI (version 1.50.0, for Windows, macOS and Linux). Paste a connection string and you get a document browser with an editable JSON view, a schema tab that samples a collection and reports each field's types and value distribution, an aggregation builder that previews every stage, and an index tab with usage counts. The schema tab earns the download: it answers "what is in here" at a glance.

The Database Tools are the command-line half, versioned separately (100.18.0 here).

The MongoDB Database Tools 1,054 and what each is for
Tool Job
mongodump / mongorestore binary BSON backup and restore, with indexes
mongoexport / mongoimport JSON, CSV and TSV interchange
bsondump turn a .bson dump file into readable JSON
mongostat / mongotop live operation counts, per-collection timings
mongofiles put and get GridFS files (GridFS)

The first two pairs are not interchangeable. mongodump writes BSON, so types, indexes and collection options survive a round trip; it is the backup tool, and replaces the automated backups an Atlas 1,815 M0 cluster lacks. mongoexport writes text, so Decimal128, dates and ObjectId become extended-JSON strings or, in CSV, lose their types.

Exporting two fields as CSV, then taking a full binary backup
mongoexport --uri="mongodb://127.0.0.1:28017/bookshelf" --collection=books \
            --fields=title,year --type=csv --out=books.csv
mongodump  --uri="mongodb://127.0.0.1:28017/bookshelf" --out=dump/
Output
2026-09-22T07:40:21.927+0800    exported 2 records
2026-09-22T07:40:22.049+0800    done dumping `bookshelf.books` (2 documents)
$ cat books.csv
title,year
Eloquent JavaScript,2024
Designing Data-Intensive Applications,2017

Both take the same --uri, so the same command runs against a container or an Atlas cluster. Add --gzip to compress a dump, --query for a subset, and --drop on mongorestore to replace rather than merge — merging is the default, and how a "restore" leaves stale documents behind.