Axum
github.com
2
Leaving SiteNav
External Link Disclaimer
You are about to visit github.com. This website is not operated by us. We are not responsible for its content or privacy practices.
About this website
Axum is an ergonomic and modular Rust web framework built by the Tokio team (led by David Pedersen), designed specifically to work seamlessly with the Tokio asynchronous runtime ecosystem. Unlike Actix Web, which is built on its own actor framework, Axum is built on top of hyper (the low-level HTTP implementation used by Tokio), tower (a modular service abstraction for request-response middleware), and tower-http (HTTP-specific middleware). This design philosophy means that Axum does not reinvent any infrastructure: it reuses the battle-tested, widely-adopted components from the Tokio ecosystem, benefiting from their maturity, performance, and community support. Key features include: a type-safe, macro-free routing system (using Router and method-specific handler functions, with routing parameters extracted via typed function arguments), the extractor pattern (similar to Actix Web, where function parameters implement the FromRequest or FromRequestParts trait and are automatically extracted from the request — State for shared application state, Path for URL parameters, Query for query strings, Json for typed request body deserialization, and custom extractors), tower middleware integration (any tower Service or Layer can be used as middleware, enabling composition with the hundreds of tower-compatible middleware in the ecosystem), a shared state pattern (via axum::extract::State for passing application-wide state like database connection pools to handlers), WebSocket support, Server-Sent Events (SSE) support, static file serving (via tower-http services), a powerful error handling system (handlers can return any type implementing IntoResponse, and custom error types can be mapped to HTTP responses), graceful shutdown, and testing utilities. Axum is particularly well-suited for building REST APIs and microservices. As of 2026, Axum has over 21,000 stars.
Statistics
2
Views
0
Clicks
0
Like
0
Dislike