Installation
Requirements
Python 3.10 or newer
MongoDB 5.0+ (local, Docker, or Atlas)
FastAPI application
Install the package
Using uv (recommended):
uv add fastapi-mongo-admin
Using pip:
pip install fastapi-mongo-admin
Development install
Clone the repository and install with dev dependencies:
git clone https://github.com/tushortz/fastapi-mongo-admin.git
cd fastapi-mongo-admin
uv sync --group dev
Documentation dependencies (optional):
uv sync --extra docs
The published PyPI package includes only fastapi_mongo_admin — docs/ and
example/ are excluded from the wheel and source distribution.
Core dependencies (installed automatically):
Package |
Purpose |
|---|---|
|
Web framework and routing |
|
Async MongoDB driver |
|
Sync MongoDB driver |
|
Model validation and schema inference |
|
Server-rendered admin templates |
|
Form data parsing |
Optional: MongoDB via Docker
For local development, start MongoDB with the included compose file:
docker compose -f example/docker-compose.yml up -d
Verify the connection:
mongosh mongodb://localhost:27017
Next steps
Continue to Quick Start to mount the admin in your FastAPI application.