Open an interactive shell to a local deployment.
Section: Connect and navigate
Start mongosh locally
bash
bash
mongoshExplanation
Starts the modern MongoDB shell and connects using default local settings when available.
Learn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Connect and navigate
Connect with a MongoDB URI
Connect directly with a full connection string.
Get collection names programmatically
Return an array of collection names.