Mongo Query Playground

Practise MongoDB shell queries in your browser. Nothing is uploaded.

About the Mongo Query Playground

Practise MongoDB shell queries without installing a database. The playground runs inside your browser tab. It follows mongosh syntax and starts with sample customers, products and orders collections. You can import your own JSON or CSV files.

It is meant for learning query and aggregation syntax and trying ideas on small data. It is not a MongoDB server: drivers and applications cannot connect, and indexes, transactions and replication are not available.

Questions

Is this real MongoDB?

No. It is an in-browser engine that follows MongoDB shell syntax. It supports common query and update operators and aggregation stages such as $match, $group, $lookup, $unwind, $project, $facet and $bucket, but not every MongoDB feature.

Can I connect to it from Java, Python or another program?

No. There is no server or connection string, so MongoDB drivers for Java, Python, Node.js and other languages cannot connect. Queries run only from the editor on this page.

Is my data uploaded?

No. The database runs inside your browser tab. Your queries and imported files never leave your device.

What files can I import?

JSON (an array of documents, one document per line, or an export with several collections) and CSV. Each file becomes a collection.

Is my data saved?

No. Reloading the page resets the collections. Use Export to download them as JSON first. The text in the editor is kept.

More playgrounds

🤖 Use this tool from an AI agent (WebMCP)

This page offers 2 tools that an AI agent running in the browser can call directly, without clicking through the page. A call runs in your tab like the buttons do, and nothing is uploaded.

How to turn it on and try it

  1. Use Chrome 149 or later on a computer. TinyPDF.in is enrolled in Chrome's WebMCP trial, so there is nothing to switch on.
  2. Keep this page open and open the console (F12, then Console).
  3. Paste this:
const tools = await document.modelContext.getTools();
const tool = tools.find(t => t.name === 'run_mongo_query');
await document.modelContext.executeTool(tool, JSON.stringify({
  "query": "db.customers.find({}).limit(2)"
}));

In other browsers the page works as usual and offers no agent tools. Examples for every tool and what they return

Using a desktop agent such as Claude Code or Cursor? See how to connect it to this page.