MongoDB viewer: browse databases and documents
MongoDB stores documents in collections. You can browse them with a MongoDB GUI or query them from mongosh. This guide covers both approaches; if you’re using plainDB, MongoDB is supported on Mac and Windows.
Connect with the correct identity
Get the connection string, authentication database and network requirements from the database owner. Remove credentials before sharing an error report. A cloud project’s web login is not automatically the same identity as a database user.
Browse from the terminal
The following are mongosh commands, not SQL and not promises about syntax accepted by every desktop editor:
show dbs
use inventory
show collectionsNames shown depend on access. Selecting a database name in the shell does not by itself prove that it contains stored data. MongoDB’s shell command guide explains the environment.
Read a few documents
This illustrative query assumes a products collection with status and name fields:
db.products.find(
{ status: "active" },
{ name: 1, status: 1 }
).sort({ _id: 1 }).limit(20)The filter chooses documents, the projection chooses fields and the limit bounds output. Compare the result with a known test document before broadening the query. See the find reference.
Documents need not all contain the same fields. Inspect several representative records before treating a single example as the collection’s schema. A missing field and an explicit null value can also matter to your application.
Compare GUI workflows
Test nested objects, arrays, large documents and exported values. Keep database-specific types in mind when moving data to plain JSON or CSV. A visual table can flatten a document for display without changing how the server stores it.
plainDB offers MongoDB browsing on supported Macs and Windows PCs. For Linux or a dedicated MongoDB workflow, evaluate an appropriate MongoDB tool such as Compass. PgAdmin is a PostgreSQL administration tool, not a MongoDB viewer.
Related: inspect JSON structure and plainDB platform coverage.