Starlette

A lightweight ASGI framework/toolkit for building async web services and apps in Python

Framework
PyPI
v1.6.0
12,549stars
BSD 3-Clause License

Repository Health

Pre-computed score based on development activity, maintenance, community, maturity, and trend momentum.How we score it →
93/100Excellent
Development Activity96
Maintenance100
Community76
Maturity60
Momentum40

Technical Analysis

AI-assessed by reading the actual repository — architecture, code quality, innovation, and documentation.How we score it →
78/100Good
Architecture85
Code Quality85
Innovation70
Learning Curve72

Starlette is a lightweight ASGI framework and toolkit for building high-performance async web services in Python. It provides the core primitives every ASGI app needs — routing, request/response objects, middleware, WebSockets, background tasks, and a test client — without imposing a large amount of structure on top, making it usable either directly or as the foundation other frameworks build on.

FastAPI is the most visible consumer of Starlette, using it for all of the underlying HTTP/WebSocket handling while layering in validation and OpenAPI generation; but Starlette itself is designed to be used standalone for services that need async performance without a full-featured framework’s opinions.

What You Get

  • ASGI-native routing with path parameters, mounting, and WebSocket routes
  • Request/Response objects, form/multipart parsing, and streaming responses
  • A composable middleware stack (CORS, GZip, sessions, trusted host, etc.)
  • Native async WebSocket support and background task scheduling
  • A TestClient built on httpx for synchronous-style testing of async apps
  • Static file serving and Jinja2 templating integration

Common Use Cases

  • Building lightweight async microservices or internal APIs without a heavier framework
  • Serving as the ASGI foundation underneath higher-level frameworks (as FastAPI does)
  • Building real-time services that need native WebSocket routing and handling
  • Adding async middleware (CORS, auth, sessions) to an existing ASGI application

Under The Hood

Architecture - applications.py assembles a Starlette app from a middleware stack (middleware/), a Router (routing.py) that dispatches ASGI scope/receive/send calls to endpoint callables or classes (endpoints.py), with request parsing (requests.py, formparsers.py) and response construction (responses.py) as thin, composable layers around the raw ASGI interface. Tech Stack - Pure-Python, dependency-light (optional extras for httpx, jinja2, python-multipart, itsdangerous depending on features used), built and packaged via modern pyproject.toml/uv tooling, deployed under any ASGI server (Uvicorn, Hypercorn, Daphne). Code Quality - A large, well-organized tests/ directory (26+ files) covers routing, middleware, WebSockets, static files, and exception handling individually, and the project enforces type checking (py.typed) and consistent style across a 300+ contributor codebase. API Design - The Starlette(routes=[...]) constructor and decorator-free route definitions keep the surface small and explicit; because it’s intentionally low-level, using it directly requires more boilerplate than a batteries-included framework, but that same minimalism is what makes it easy to build other frameworks on top of.

Used by 18 apps in this directory

Python
100%
Apache 2.0

Agno

Devops · AI Development · Automation

41,774

Build, run, and manage agent platforms with a full production stack — SDK, runtime, and control plane included.

View details
93
Repo Health
87
Technical
67
Dependency
Built with
Python100%
Updated today
Python
90%
Apache 2.0

Apache Airflow

Data Engineering

46,530

Define, schedule, and monitor complex data workflows as Python code — with a powerful UI, 80+ provider integrations, and battle-tested scalability across thousands of production deployments.

View details
96
Repo Health
89
Technical
66
Dependency
Built with
Python90%
Updated today
Python
63%
Apache 2.0

GPT Researcher

Productivity · AI Assistants

29,039

The pioneering open-source autonomous AI agent that conducts deep, multi-source research and produces citation-backed reports exceeding 2,000 words — faster and more reliably than any human researcher.

View details
88
Repo Health
91
Technical
64
Dependency
Built with
Python63%
TypeScript23%
Updated 1 months ago
Python
100%
MIT

Graphify

AI Agents

108,063

A YC-backed, open-source knowledge graph skill for AI coding assistants — type /graphify and it maps your entire project (code, docs, PDFs, images, videos) into a queryable graph instead of grepping through files.

View details
82
Repo Health
73
Technical
78
Dependency
Built with
Python100%
Updated 2 days ago
Python
80%
Apache 2.0

headroom

AI Development · Developer Tools

66,835

Compress everything your AI agent reads — tool outputs, logs, RAG chunks, and files — before it reaches the LLM, achieving 60–95% fewer tokens with the same answers.

View details
84
Repo Health
86
Technical
73
Dependency
Built with
Python80%
Rust14%
Updated today
TypeScript
91%
Apache 2.0

Helicone

Monitoring · AI Development · Analytics

6,083

An open-source AI gateway and LLM observability platform that routes requests to 100+ models while logging cost, latency, and full traces for every call.

View details
62
Repo Health
81
Technical
66
Dependency
Built with
TypeScript91%
Updated 3 days ago
Python
83%
Apache 2.0

knowhere

AI Development · Developer Tools

2,515

Transform messy, unstructured documents into persistent, navigable memory that AI agents can actually use.

View details
83
Repo Health
75
Technical
70
Dependency
Built with
Python83%
HTML16%
Updated today
Python
84%
MIT

LiteLLM

AI Development · Developer Tools

56,720

Open source AI gateway and Python SDK that gives you one OpenAI-compatible interface to call 100+ LLM providers, with built-in routing, cost tracking, guardrails, and virtual keys.

View details
92
Repo Health
81
Technical
71
Dependency
Built with
Python84%
TypeScript14%
Updated today
Python
61%
Apache 2.0

marimo

Developer Tools · Data Engineering

22,393

A reactive Python notebook that eliminates hidden state, runs reproducibly, and deploys as a web app or script — stored as pure Python, built for the AI era.

View details
90
Repo Health
91
Technical
66
Dependency
Built with
Python61%
TypeScript37%
Updated today

Join founders buildingwith open source

Opinionated takes, migration guides, cost-saving tips, and insights from the open source ecosystem.

Subscribe on Substack
Join 750+ subscribers

Search