Starlette-admin is an open-source Python framework that generates a feature-rich administrative interface for Starlette and FastAPI applications, turning your ORM models into a ready-to-use CRUD dashboard. The project was created because FastAPI has no mature admin-interface solution equivalent to Flask-Admin; existing options like Sqladmin and Fastapi-Admin each only support a single ORM, while starlette-admin works with several data layers by default.
What is starlette-admin?
Starlette-admin is a library for the Starlette ASGI ecosystem, including FastAPI, that provides a complete CRUD interface for any supported data backend. As input, it takes your model definitions written with SQLAlchemy, SQLModel, MongoEngine, ODMantic, or a custom backend, and as output it produces a web-based admin panel with listing, forms, search, and export functionality mounted directly onto your application. The framework is maintained on GitHub by the developer jowilf and distributed through the Python Package Index, installable with pip or Poetry. The project has gained more than 1,000 stars on GitHub.
Key Features
- ORM-agnostic CRUD — Works out of the box with SQLAlchemy, SQLModel, MongoEngine, ODMantic, and a custom data layer backend, so you are not locked into one database technology.
- Automatic form validation — Forms are generated from your model definitions and validated on submission, removing the need to write manual field validators.
- Advanced table widget — Built on DataTables, the grid supports search, filtering, search highlighting, and multi-column ordering across your records.
- Export options — Export data to CSV, Excel, PDF, and browser print directly from the interface.
- Authentication and authorization — Includes security features to restrict admin access and protect sensitive areas.
- File management — Manage file uploads and stored assets within the admin panel.
- Custom views and batch actions — Extend the UI with your own views and define custom batch actions that operate on multiple selected rows.
- Internationalization — The interface supports translations for multi-language deployments.
Who is it for?
- FastAPI developers who need a quick admin backend for their API without building HTML CRUD pages by hand.
- Full-stack teams using SQLAlchemy, SQLModel, or MongoDB with FastAPI who want a consistent data-management UI.
- Operators and support staff in an organization that uses a Starlette/FastAPI service and needs a user-friendly internal dashboard.
- Developers with non-standard storage who need a custom data layer; the project provides a base model view and example to extend.
What can you do with starlette-admin?
- Manipulate your records — Add, edit, delete, and view rows from any supported ORM through the generated interface, with validation and search built in.
- Export and print data — Select columns and rows and export to CSV, Excel, PDF, or send to a printer for reporting.
- Manage user permissions — Set up authentication and authorization so different admins have restricted or full access.
- Customize the interface — Add your own views and batch actions to automate repetitive admin workflows.
How does starlette-admin work?
The setup follows a short workflow: install the package, define your ORM model, create an Admin instance with your database engine, register ModelView classes for your models, and mount the admin onto your Starlette or FastAPI app. The quick-start example in the documentation uses SQLAlchemy, creates a Post model, and exposes the admin at http://localhost:8000/admin in under 20 lines of code. The documentation and a live demo with source code are linked from the project repository.
Alternatives
- Sqladmin — a SQLAlchemy-only admin interface for FastAPI, so it cannot be used with MongoDB ODM libraries.
- Fastapi-Admin — another admin panel library that only supports specific ORMs like Tortoise ORM, unlike starlette-admin's multi-backend approach.
