Version 1.3.0 is live

Mongo-shaped.
Embedded by design.

A familiar PyMongo-style document API backed by local storage. Ship tests, tools, prototypes, and full applications without standing up a database server.

Python 3.9–3.14 Sync + async macOS · Linux · Windows
app.py embedded
import tinymongo as pymongo

client = pymongo.MongoClient(
    tinymongo_folder="./data",
    backend="sqlite",
)

users = client.app.users
users.insert_one({
    "name": "Ada",
    "score": 98,
})

result = users.find_one({
    "score": {"$gte": 90}
})
{ "name": "Ada", "score": 98 } 0.08 ms
01 No daemon
08 Storage choices
54ksharded point reads/s
425ksharded scan docs/s
100%tested coverage
0services required
One API, your storage

Start tiny.
Stay flexible.

TinyMongo keeps the document model you know while letting the application own its data. Begin in memory, persist to SQLite, analyze with Parquet, or point the same interface at remote SQL.

01

Drop-in thinking

Use familiar clients, databases, collections, cursors, filters, updates, indexes, projections, and aggregation without operating MongoDB.

Explore the API
02

Storage that fits

Memory for tests. JSON for portability. SQLite for transactions. Columnar files for analytical workflows.

03

Scale embedded writes

The experimental sharded SQLite backend spreads stable IDs across independent WAL files for concurrent writers.

04

Async without theater

Storage, serialization, and lock waits run outside the event loop. The synchronous and asynchronous APIs share the same behavior.

Backend spectrum

Local first.
Remote when ready.

Choose at client construction. Your application code keeps the same document-oriented shape while the backend handles persistence.

02

JSON / TinyDB

Human-readable, portable persistence with atomic file replacement.

default
03

SQLite

Table-native storage, transactions, indexes, WAL, and precise point reads.

production
04

SQLite sharded

Independent files unlock concurrent embedded writers and parallel reads.

experimental
05

DuckDB + Parquet

Columnar options for local analytics and interoperable datasets.

analytics
06

PostgreSQL + MariaDB

Move beyond one machine while preserving the TinyMongo interface.

remote SQL
Live playground

Query TinyMongo.
Right here.

This is a real TinyMongo query against a fixed in-memory collection. Try a preset or edit the safe JSON request. No account, persistence, or executable code.

constrained sandbox
request.json⌘ + Enter to run
resultready
Press “Run query” to execute against TinyMongo 1.3.0.
Built to be inspected

Open source.
No black boxes.

Read the implementation, run the full test matrix, reproduce the benchmarks, and choose exactly which optional dependencies enter your project.

CI matrix passing
CPython 3.9
CPython 3.10
CPython 3.11
CPython 3.12
CPython 3.13
CPython 3.14
macOSLinuxWindows
Your data. Your process.

Build without
the database ceremony.

One package. A familiar API. Storage that starts wherever your application does.

Star on GitHub