A simple HTTP server in Rust

Fast, lightweight, and zero dependencies. Perfect for development and small projects.

hteapot illustration

Features

Fast

Built with Rust for maximum performance and minimal resource usage

Simple

Easy to use with a clean API and minimal configuration required

Zero Dependencies

No external dependencies means smaller binaries and better security

Quick Start

Terminal
# Install hteapot
cargo install hteapot

# Start the server
hteapot config.toml
config.toml
[HTEAPOT]
port = 8081
host = "0.0.0.0"
threads = 4
root = "public"
cache = true
cache_ttl = 36
[proxy]
"/test" = "http://example.com"
main.rs
use hteapot::{HttpStatus, HttpResponse, Hteapot, HttpRequest};

fn main() {
    let server = Hteapot::new("localhost", 8081);
    server.listen(move |req: HttpRequest| {
        // This will be executed for each request
        HttpResponse::new(HttpStatus::IAmATeapot, "Hello, I am HTeaPot", None)
    });
}
}

Download hteapot

Get the latest version of hteapot for your platform. Pre-compiled binaries are available for all major operating systems.

Windows

Loading...

Linux

Loading...

macOS

Loading...

Alternative Installation Methods

Cargo (Rust)

cargo install hteapot

From Source

git clone && cargo build --release

Ready to get started?

hteapot is open source and free to use. Start building your applications with a simple, fast HTTP server.