Skip to content
fastware vs Starlette
Edit
On this page

Comparison of fastware and Starlette: batteries-included framework (SSE, auth, server lifecycle) vs lightweight modular ASGI toolkit.

#fastware vs Starlette

Starlette is a lightweight ASGI toolkit that provides the building blocks for web applications. FastAPI, for example, is built on top of Starlette. fastware is a batteries-included framework that provides the assembled product -- routing, server management, SSE, auth, and middleware all ship together.

#Toolkit vs framework

The core difference is scope and assembly level. Starlette gives you the parts and leaves assembly to you; fastware gives you the assembled product with 5 built-in middleware classes, a managed Granian server, SSE broadcasting, auth, and DI all wired together out of the box:

Starlette provides building blocks. You get a router, request/response classes, middleware protocol, WebSocket support, and a test client. You assemble them into an application, choose a server (Uvicorn, Hypercorn, Daphne), configure middleware, pick a JSON library, add auth, and wire up SSE yourself.

fastware provides the assembled product. You get the same building blocks, but also a managed Granian server, SSE broadcaster, auth module, dependency injection, feature flags, error logging, background tasks, dev mode with Vite proxy, and a CLI -- all designed to work together.

#Feature comparison

Feature comparison
fastwareStarlette
RoutingRouter with {param}, {param:int}, {param:path}Router with {param}, {param:int}, {param:path}, {param:float}
Request/ResponseRequest, JSONResponse, HTMLResponse, StreamResponse, FileResponse, etc.Request, JSONResponse, HTMLResponse, StreamingResponse, FileResponse, etc.
JSON enginemsgspec (10-75x faster than stdlib json)stdlib json
ASGI serverGranian (managed lifecycle, PID files, stop/status)None (BYO: Uvicorn, Hypercorn, etc.)
Middleware5 built-in (CORS, RequestID, RequestTiming, TrustedHost, ViteDevProxy)5 built-in (CORS, TrustedHost, HTTPSRedirect, GZip, Sessions)
SSEBuilt-in Broadcaster with typed events, heartbeat, auto-pruningNot included (use StreamingResponse manually)
WebSocketSupported with DISupported
Dependency injectionDependencyResolver (sync/async factories, generator cleanup)Not included
AuthJWT, passwords, CSRF, rate limiting, user storageNot included
Background tasksTaskRegistry with feature gatingBackgroundTask (per-response, no registry)
Test clientBuilt-in TestClient and AsyncTestClientTestClient (based on httpx)
Static filesBuilt-in with SPA fallbackStaticFiles (no SPA fallback)
Dev modedev() with Vite proxy and HMRNot included
Feature flagsBuilt-in FeatureFlagsNot included
Error logSQLite-backed ErrorLogNot included
Exception handlersPer-type with MRO-based priorityPer-type
Mount sub-appsrouter.mount(prefix, app)Mount(path, app)
LifespanAsync context managerAsync context manager

#What Starlette does differently

Starlette is intentionally minimal -- it ships with only 2 required dependencies (anyio and typing_extensions) compared to fastware's 2 required dependencies (msgspec and granian). But Starlette's minimalism is a deliberate design choice that enables flexibility, and comes with 5 concrete advantages:

  • Lighter dependency footprint: Starlette has no required dependencies beyond anyio and typing_extensions. fastware requires msgspec and granian.
  • More server choices: Because Starlette does not manage a server, you can run it on Uvicorn, Hypercorn, Daphne, or any ASGI server. fastware is opinionated about Granian.
  • Foundation for other frameworks: Starlette is designed to be built upon. FastAPI, Starlite (now Litestar), and others extend it. fastware is a standalone framework, not a toolkit for building frameworks.
  • HTTPSRedirect and GZip middleware: Starlette includes these out of the box. fastware does not have them built in.
  • Sessions middleware: Starlette has cookie-based sessions. fastware has JWT-based auth with session cookies, which is a different approach.
  • Mature and battle-tested: Starlette has been in production at scale for years. fastware is new.

#When to choose fastware

  • You want a framework that includes everything from auth to server management, rather than assembling pieces yourself.
  • You want msgspec performance for JSON serialization without manually wiring it in.
  • You need SSE broadcasting as a first-class feature.
  • You want serve() / stop() / status() with PID files and process management instead of configuring a server separately.
  • You are building a full-stack app with Vite and want the dev proxy built in.

#When to choose Starlette

  • You want a minimal toolkit and prefer to choose each component yourself.
  • You need to run on a server other than Granian (Uvicorn, Hypercorn, Daphne).
  • You are building a framework on top of ASGI foundations rather than an application.
  • You want the lightest possible dependency footprint.
  • You need the maturity and community support of a well-established project.

More tools from this site

  • claudestream Drive Claude Code from Python: run it as a subprocess and read its output as typed events, with async and sync sessions, sandbox policies, and tools you define in Python
  • claudewheel A TUI Claude Code Launcher that lets you have more than one profile, manage sessions lifecycle, pick the exact CC version, model to use (even older unlisted ones), pick which GitHub account to use, etc.
  • dirstat Fast, single-binary directory statistics CLI: every file under a tree grouped by format, with counts, sizes, and lines of code, as a colored terminal table or as JSON
  • go-toml-edit Zero-dep TOML editing library for Go with comment preservation
  • howmuchleft The fastest Claude Code statusline: context window, 5-hour, and weekly limit usage as three customizable gradient bars, rendering in about 6 ms
  • orxtra
  • pgdesign
  • predraw Declarative rendering pipeline: describe a scene in JSON and get SVG, PNG and WebP out, with light and dark style tokens, reusable components and text converted to path outlines
  • reposummary Turn a git repository's history into a Markdown journal: pick a time window or revision range and get a readable digest of what changed, optionally narrated by an LLM
  • rlsbl Release orchestration and project scaffolding CLI that bumps versions, validates a structured JSONL changelog, tags only the commit CI verified, and publishes to npm, PyPI, Go and more
  • safegit git wrapper CLI that gives each commit its own temporary index and retries ref updates on conflict, so concurrent agents share one repository
  • saferm Command-line replacement for rm that archives every deletion with a mandatory reason and the context it ran in, so deleted files can be listed, inspected and restored
  • selfdoc Static Site Generator that builds a project's documentation site directly from its source code, so the docs can never drift from the code they describe, with SEO/AEO, first-class blog, search, and cross-project linking built in
  • strictcli
  • stricttest An always-on test-isolation floor: a pytest plugin and a Go env-hygiene module that make a test suite structurally unable to reach real credentials, the real HOME, the network, or the development repository.
  • wesktop A Python framework that turns an ASGI web app into a desktop application, serving it from a local Granian server and displaying it in a native OS window via pywebview
Search