mongosh

officialcautiondatabasebrew

MongoDB · MongoDB, database inspection, and queries from the terminal.

$ brew install mongosh
One-liner to try
$ mongosh --version

Agent pack

Copy into an agent

A markdown-ready setup brief with install, verify, safe starting commands, and guardrails for AI agents.

Open .md
Readiness
Usable with guardrails · 50/100
Verify
mongosh --version
Agent URL
/cli/mongosh/agent.md

Quick reference

Installbrew install mongosh
Verifymongosh --version
First commandmongosh --version

About

The official CLI from MongoDB. MongoDB, database inspection, and queries from the terminal.

Example workflow

1. mongosh --version

Alternatives worth considering