axum

Ergonomic and modular HTTP routing and request-handling framework for Rust, built on Tokio, Hyper, and Tower.

Framework
Cargo
v0.8.9
27,031stars
MIT License

Repository Health

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

Technical Analysis

AI-assessed by reading the actual repository — architecture, code quality, innovation, and documentation.How we score it →
91/100Excellent
Architecture92
Code Quality90
Innovation92
Learning Curve85

Axum is a web application framework for Rust that focuses on ergonomics and modularity. It routes requests to handlers with a macro-free API, parses requests declaratively through extractors, and produces responses with minimal boilerplate, giving you a predictable model for building HTTP services and JSON APIs.

Rather than shipping its own middleware system, axum builds directly on tower::Service, so it inherits the entire Tower and tower-http ecosystem — timeouts, tracing, compression, authorization, and more — for free. Because it is a thin layer over Hyper, it adds very little overhead while remaining interoperable with any application built on hyper or tonic.

What You Get

  • A macro-free Router API for declaratively mapping paths and HTTP methods to async handler functions
  • A rich extractor system (Json, Path, Query, State, Form, Multipart, and custom FromRequest types) for typed, declarative request parsing
  • First-class access to the Tower and tower-http middleware ecosystem — tracing, compression, CORS, timeouts, authorization, and more
  • Built-in helpers for WebSockets, multipart forms, typed state sharing, and graceful shutdown
  • 100% safe Rust (#![forbid(unsafe_code)]) with a thin, low-overhead layer over Hyper

Common Use Cases

  • Building JSON REST APIs and backend services for web and mobile clients
  • Serving real-time features over WebSockets alongside conventional HTTP routes
  • Composing microservices that share Tower middleware with hyper- or tonic-based systems
  • Standing up internal tools, proxies, and metrics endpoints with minimal boilerplate

Under The Hood

Architecture

Axum layers a small routing and handler-dispatch surface over Hyper and Tower. The public entry point is Router (in src/routing/mod.rs), which combines a path_router built on the matchit radix-tree matcher with per-path method_routing to dispatch requests. Handlers become services through the Handler trait (src/handler/), which uses a set of tuple implementations so functions with up to sixteen extractor arguments implement the trait automatically. Request data is pulled out declaratively by extractors implementing FromRequest/FromRequestParts (src/extract/), and results are turned into responses via IntoResponse. Everything terminates in a tower_service::Service, and axum::serve (src/serve/) drives the whole stack over a hyper-util connection using a Tokio TcpListener.

Tech Stack

Written in Rust (edition 2021, MSRV 1.80) with a Cargo workspace splitting the crate into axum, axum-core, axum-extra, and axum-macros. Core dependencies are hyper (HTTP implementation), tower/tower-layer/tower-service (middleware), http/http-body, bytes, matchit (route matching), and serde/serde_json for JSON. Optional cargo features (json, ws, multipart, macros, http2, tracing, and others) keep the compiled surface minimal, and tokio provides the async runtime.

Code Quality

The crate uses #![forbid(unsafe_code)] to guarantee 100% safe Rust and carries an extensive test suite — dozens of dedicated test modules across routing, extractors, and middleware. Code is organized into small, focused modules with clear naming, strongly typed public APIs, and a predictable, documented error-handling model. Development is very active (443 contributors, hundreds of releases) and releases follow a disciplined workspace-versioning scheme.

API Design

Axum’s public API is its headline strength: a macro-free, composable builder (Router::new().route(...)) reads naturally, extractors make request parsing declarative and type-checked, and IntoResponse removes response boilerplate. Documentation is thorough — a heavily annotated crate doc plus a large examples/ directory (hello-world, JWT, WebSockets, database integrations, graceful shutdown, and more) — so a working server takes only a handful of lines to stand up.

Used by 31 apps in this directory

Rust
86%
Other

Arroyo

Data Engineering · Analytics

5,029

A distributed stream processing engine written in Rust that lets you write SQL to run stateful, real-time computations over data streams with subsecond results.

View details
86
Repo Health
74
Technical
62
Dependency
Built with
Rust86%
Updated 3 days ago
Rust
54%
Other

Cameleer

AI Agents

23

A local-first desktop workspace for managing AI agents in an enterprise-style workflow — agent directory, Kanban task tracking, workspace chat, and a full runtime/audit log of agent actions and tool approvals.

View details
41
Repo Health
65
Technical
76
Dependency
Built with
Rust54%
JavaScript24%
TypeScript15%
Updated 1 months ago
Rust
53%
Other

Cap

Team Chat · Video Conferencing

21,859

Open source Loom alternative with GPU-accelerated recording, instant share links, AI summaries, and full self-hosting via Docker Compose.

View details
89
Repo Health
81
Technical
64
Dependency
Built with
Rust53%
TypeScript43%
Updated yesterday
Rust
95%
MIT

claw-code

AI Agents · AI Code Assistants

195,189

A Rust-built CLI agent harness for Claude AI with persistent sessions, MCP tool integration, plugin hooks, and multi-provider support — designed to run autonomous coding workflows without human babysitting.

View details
57
Repo Health
71
Technical
77
Dependency
Built with
Rust95%
Updated 3 weeks ago
Swift
64%
GPL 3.0

cmux

Developer Tools · AI Development

26,845

A native, Ghostty-based macOS terminal with vertical tabs, agent-aware notifications, and a scriptable browser built for running many parallel AI coding agent sessions instead of juggling tmux panes.

View details
84
Repo Health
81
Technical
72
Dependency
Built with
Swift64%
Rust14%
Updated today
Svelte
46%
MIT

Cryptgeon

File Storage · Security

1,517

Self-destructing encrypted notes and files that vanish after viewing — the server never sees your keys.

View details
75
Repo Health
80
Technical
74
Dependency
Built with
Svelte46%
TypeScript30%
Rust14%
Updated yesterday
Go
32%
Apache 2.0

CubeSandbox

Developer Tools · Security · AI Agents

11,816

Instant, concurrent, hardware-isolated MicroVM sandboxes for AI agents — E2B-API compatible, sub-60ms cold starts, and a built-in zero-trust egress proxy, all self-hostable at scale.

View details
83
Repo Health
88
Technical
63
Dependency
Built with
Go32%
Rust28%
C23%
Updated yesterday
Go
32%
Apache 2.0

CubeSandbox

Developer Tools · Security · AI Agents

11,816

Instant, concurrent, hardware-isolated MicroVM sandboxes for AI agents — E2B-API compatible, sub-60ms cold starts, and a built-in zero-trust egress proxy, all self-hostable at scale.

View details
83
Repo Health
88
Technical
63
Dependency
Built with
Go32%
Rust28%
C23%
Updated yesterday
TypeScript
89%
Other

FastGPT

AI Agents · AI Development

29,591

Build, debug, and deploy knowledge-based AI agents with a visual workflow editor, RAG retrieval, and support for any OpenAI-compatible LLM.

View details
93
Repo Health
84
Technical
69
Dependency
Built with
TypeScript89%
Updated yesterday

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