
warp
A Rust web server framework built from small composable filters for handling HTTP requests.
- Stars
- 10.4k
- Forks
- 746
- Licence
- MIT
- Language
- Rust
- Last update
- 3 months ago
- Type
- Library
What it is
warp is a web server framework for the Rust programming language. It lets developers describe what a request must look like (its path, headers, query string, or body) by combining small building blocks called filters, then write the code that answers matching requests. It is built on top of hyper, so it supports HTTP/1 and HTTP/2 and runs asynchronously.
- Serve a JSON API that responds to routes such as GET /hello/:name
- Accept form submissions or multipart file uploads
- Serve static files and directories from disk
- Add websocket endpoints to a Rust server
- Compress responses with Gzip, Deflate, or Brotli
Great for
- Rust developers building HTTP APIs or web servers
- Developers who like composing small reusable request-handling pieces
- Projects that need routing, JSON or form handling, websockets, or static files in one framework
- Teams already using Tokio for asynchronous Rust code
Not ideal for
- People who do not write Rust, since the README only shows Rust examples
- Beginners new to both Rust and async programming, as the filter model and Tokio setup take time to learn
- Projects needing a long-term stability guarantee, since the latest release is v0.4.1 and the README does not describe its support policy
How to get it
- 1
Install with a package manager
You'll need: Rust toolchain with Cargo · Tokio async runtime (added as a dependency)
Add warp and Tokio to Cargo.toml
tokio = { version = "1", features = ["full"] } warp = { version = "0.4", features = ["server"] } - 2
Run it
- Add the tokio and warp lines to your Cargo.toml dependencies
- Copy the example from the README into src/main.rs
- Run the project with cargo run
- Open http://127.0.0.1:3030/hello/warp in a browser to see the response
- 3
Get the most out of it
- Read the docs at docs.rs/warp for the full filter API
- Browse the examples folder in the GitHub repository for patterns such as websockets and file serving
- Combine filters with .map and similar combinators to build larger routes from smaller ones
- Enable the compression features described in the README for Gzip, Deflate, or Brotli responses
Downloads
Strengths
- Routing and request matching are expressed as composable filters, which the README presents as the core design
- Covers many common needs out of the box, including websockets, compression, and access logging
- Built on hyper, which the README says provides HTTP/1, HTTP/2, and async support
Trade-offs
- Requires working knowledge of Rust and the Tokio async runtime
- The README is brief and points to external docs and examples for detail
- The README does not state a stability or maintenance commitment beyond the latest release date
How it compares
| Project | Stars | Type | Level | Updated | Best for |
|---|---|---|---|---|---|
| warp (this) | 10.4k | Library | intermediate | 3 months ago | Rust developers building HTTP APIs or web servers |
| axum | 27.7k | Library | intermediate | 5 days ago | Rust developers building HTTP APIs or web services |
| vapor | 26.2k | Library | intermediate | 4 days ago | Swift developers who want to build backend services in the same language as their iOS or macOS apps |
| elysia | 19.3k | Framework | intermediate | 9 days ago | TypeScript developers building HTTP APIs or web servers |
| gin | 89.5k | Library | intermediate | 27 days ago | Go developers building REST APIs |
| kratos | 26k | Library | intermediate | 5 days ago | Go developers building a set of backend services that talk over HTTP or gRPC |
Stats synced from GitHub. The assessment above was drafted with AI from the project's README on 2026-10-29 and may miss recent changes — check the README before relying on a command. MIT licence: free to use, modify and distribute, including commercially, as long as you keep the copyright notice.