| Project | Status | |
|---|---|---|
| CI/CD | ||
| Quality | ||
| Package | ||
| Community | ||
| Meta |
Litestar is a powerful, flexible yet opinionated ASGI framework, focused on building APIs. It offers high-performance data validation, dependency injection, first-class ORM integration, authorization primitives, a rich plugin API, middleware, and much more that's needed to get applications up and running.
Check out the documentation 📚 for a detailed overview of its features!
Additionally, the Litestar fullstack repository can give you a good impression how a fully fledged Litestar application may look.
Table of Contents
pip install litestar
or to include the CLI and a server (uvicorn) for running your application:
pip install 'litestar[standard]'
```python title="app.py" from litestar import Litestar, get
@get("/") async def hello_world() -> dict[str, str]: """Keeping the tradition alive with hello world.""" return {"hello": "world"}
app = Litestar(route_handlers=[hello_world])
And run it with
```bash
litestar run
dataclasses, TypedDict, msgspec, pydantic version 1 and version 2 (even within the same application) and (c)attrsPre-built Example Apps
Litestar is an open-source project, and we enjoy the support of our sponsors to help fund the exciting work we do.
A huge thanks to our sponsors:
<a href="https://telemetrysports.com/" title="Telemetry Sports - Changing the way data
$ claude mcp add litestar \
-- python -m otcore.mcp_server <graph>