{"id":48845231,"url":"https://github.com/fasthttpd/fasthttpd","last_synced_at":"2026-04-15T05:00:59.088Z","repository":{"id":37093684,"uuid":"489225763","full_name":"fasthttpd/fasthttpd","owner":"fasthttpd","description":"FastHttpd is a lightweight http server using valyala/fasthttp.","archived":false,"fork":false,"pushed_at":"2026-04-09T04:59:39.000Z","size":288,"stargazers_count":5,"open_issues_count":2,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-04-09T05:34:21.978Z","etag":null,"topics":["fasthttp","fasthttpd","go","http-server"],"latest_commit_sha":null,"homepage":"https://fasthttpd.org","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/fasthttpd.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2022-05-06T05:20:17.000Z","updated_at":"2026-04-09T04:58:08.000Z","dependencies_parsed_at":"2024-05-02T05:39:21.111Z","dependency_job_id":"eea95f8e-078a-483f-adba-e12d5d2734ac","html_url":"https://github.com/fasthttpd/fasthttpd","commit_stats":null,"previous_names":[],"tags_count":29,"template":false,"template_full_name":null,"purl":"pkg:github/fasthttpd/fasthttpd","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fasthttpd%2Ffasthttpd","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fasthttpd%2Ffasthttpd/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fasthttpd%2Ffasthttpd/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fasthttpd%2Ffasthttpd/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fasthttpd","download_url":"https://codeload.github.com/fasthttpd/fasthttpd/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fasthttpd%2Ffasthttpd/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31826902,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-14T18:05:02.291Z","status":"online","status_checked_at":"2026-04-15T02:00:06.175Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["fasthttp","fasthttpd","go","http-server"],"created_at":"2026-04-15T05:00:58.458Z","updated_at":"2026-04-15T05:00:59.069Z","avatar_url":"https://github.com/fasthttpd.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# FastHttpd\n\n[![PkgGoDev](https://pkg.go.dev/badge/github.com/fasthttpd/fasthttpd)](https://pkg.go.dev/github.com/fasthttpd/fasthttpd)\n[![Report Card](https://goreportcard.com/badge/github.com/fasthttpd/fasthttpd)](https://goreportcard.com/report/github.com/fasthttpd/fasthttpd)\n\nFastHttpd is a lightweight http server using [valyala/fasthttp](https://github.com/valyala/fasthttp).\n\n\u003e FastHttpd and fasthttp are versioned independently. FastHttpd **v0.8.0** is built against fasthttp **v1.70.0**.\n\n## Features\n\n- Serve static files\n- Simple routing\n- Access logging (NCSA-style, JSON or LTSV, allocation-free hot path)\n- Reverse proxy\n- Customize headers\n- Support TLS (HTTPS/SSL)\n- Automatic TLS certificates via Let's Encrypt (autocert / ACME)\n- Virtual hosts\n- YAML configuration\n\n## Installation\n\n### Go install\n\n```sh\ngo install github.com/fasthttpd/fasthttpd/cmd/fasthttpd@latest\n```\n\n### Download binary\n\nDownload binary from [release](https://github.com/fasthttpd/fasthttpd/releases).\n\n```sh\nVERSION=0.8.0 GOOS=linux GOARCH=amd64; \\\n  curl -fsSL \"https://github.com/fasthttpd/fasthttpd/releases/download/v${VERSION}/fasthttpd_${VERSION}_${GOOS}_${GOARCH}.tar.gz\" | \\\n  tar xz fasthttpd \u0026\u0026 \\\n  sudo mv fasthttpd /usr/sbin\n```\n\n- GOOS supports `linux` `darwin` `windows`\n- GOARCH supports `amd64` `arm64` `386`\n\n### Homebrew\n\n```sh\nbrew tap fasthttpd/fasthttpd\nbrew install fasthttpd\n```\n\n### Using yum or apt\n\nDownload deb or rpm from [release](https://github.com/fasthttpd/fasthttpd/releases), and then execute `apt install` or `yum install`. \n\n```sh\nVERSION=0.8.0 ARCH=amd64; \\\n  curl -fsSL -O \"https://github.com/fasthttpd/fasthttpd/releases/download/v${VERSION}/fasthttpd_${VERSION}_${ARCH}.deb\"\nsudo apt install \"./fasthttpd_${VERSION}_${ARCH}.deb\"\n```\n\n- Default configuration path is /etc/fasthttpd/config.yaml\n- Default log directory is /var/log/fasthttpd\n- FastHttpd is automatically started by systemd\n\n### Docker\n\nSee [https://hub.docker.com/r/fasthttpd/fasthttpd](https://hub.docker.com/r/fasthttpd/fasthttpd)\n\n```\ndocker run --rm -p 8080:80 fasthttpd/fasthttpd\n```\n\nThen you can hit http://localhost:8080 in your browser.\n\n## Quick start\n\nUsage\n\n```sh\nFastHttpd is a HTTP server using valyala/fasthttp.\n\nUsage:\n  fasthttpd [flags] [query] ([file...])\n\nFlags:\n  -e value\n    \tedit expression (eg. -e KEY=VALUE)\n  -f string\n    \tconfiguration file\n  -h\thelp for fasthttpd\n  -v\tprint version\n```\n\nExamples\n\n```sh\n% fasthttpd -f examples/config.minimal.yaml\n% fasthttpd -f examples/config.minimal.yaml -e accessLog.output=stdout\n% fasthttpd -e root=./examples/public -e listen=0.0.0.0:8080\n```\n\n## Configuration\n\nFor the full reference, see [docs/configuration.md](docs/configuration.md).\nFor enabling Let's Encrypt (autocert), see [examples/config.autocert.yaml](examples/config.autocert.yaml).\n\nThe following is a minimal configuration built into fasthttpd.\n\n```yaml\nhost: localhost\nlisten: ':8080'\nroot: ./public\nlog:\n  output: stderr\n\nhandlers:\n  'static':\n    type: fs\n    indexNames: [index.html]\n\nroutes:\n  - path: /\n    handler: static\n```\n\nFor a fuller configuration that exercises most of FastHttpd's features, see [docs/configuration.md](docs/configuration.md).\n\n## Override configuration using edit option\n\nFastHttpd can override some of the values in config.yaml with the -e option via [mojatter/tree](https://github.com/mojatter/tree).\n\nCustomize content root\n\n```sh\nfasthttpd -f config.yaml -e root=/custom-root\n```\n\nShow access log and disable other log\n\n```sh\nfasthttpd -f config.yaml -e log.output=\"\" -e accessLog.output=stdout\n```\n\n## RoutesCache\n\nThe following is a benchmark report of route. \nThis report shows that caching is effective when routing makes heavy use of regular expressions.\n\nSince v0.6.0 the cached route path is fully allocation-free, thanks to the\n`maphash`-based `CacheKeyBuilder` used for cache key construction.\n\n```\n% GOMAXPROCS=1 go test -bench=. -benchmem ./pkg/route/... -benchtime=10s\ngoos: darwin\ngoarch: arm64\npkg: github.com/fasthttpd/fasthttpd/pkg/route\ncpu: Apple M4\nBenchmarkRoutes_Equal        \t920876146\t        13.20 ns/op\t       0 B/op\t       0 allocs/op\nBenchmarkCachedRoutes_Equal  \t135314598\t        89.03 ns/op\t       0 B/op\t       0 allocs/op\nBenchmarkRoutes_Prefix       \t746245645\t        16.05 ns/op\t       0 B/op\t       0 allocs/op\nBenchmarkCachedRoutes_Prefix \t134016280\t        89.55 ns/op\t       0 B/op\t       0 allocs/op\nBenchmarkRoutes_Regexp       \t75967437\t       158.1 ns/op\t       0 B/op\t       0 allocs/op\nBenchmarkCachedRoutes_Regexp \t133490258\t        89.56 ns/op\t       0 B/op\t       0 allocs/op\n```\n\n## Access log\n\nFastHttpd writes access logs through a `bufio.Writer` + `sync.Pool` pipeline that keeps the formatting hot path allocation-free for the classic NCSA format, the JSON preset and the LTSV preset.\n\nSee [docs/access-log.md](docs/access-log.md) for format options, JSON / LTSV schema and field-level notes.\n\n### Benchmark\n\n```\n% GOMAXPROCS=10 go test -bench='BenchmarkAccessLog_(Common|Combined|JSON|LTSV)$' -benchmem -benchtime=3s ./pkg/logger/accesslog/\ngoos: darwin\ngoarch: arm64\npkg: github.com/fasthttpd/fasthttpd/pkg/logger/accesslog\ncpu: Apple M4\nBenchmarkAccessLog_Common-10      17620472          187.6 ns/op       0 B/op       0 allocs/op\nBenchmarkAccessLog_Combined-10    17296656          209.6 ns/op       0 B/op       0 allocs/op\nBenchmarkAccessLog_JSON-10        14670214          243.3 ns/op       0 B/op       0 allocs/op\nBenchmarkAccessLog_LTSV-10        17862510          201.7 ns/op       0 B/op       0 allocs/op\n```\n\n## Third-party library licenses\n\n- [valyala/fasthttp](https://github.com/valyala/fasthttp)\n- [natefinch/lumberjack](https://github.com/natefinch/lumberjack)\n- [zehuamama/balancer](https://github.com/zehuamama/balancer)\n- [mojatter/tree](https://github.com/mojatter/tree)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffasthttpd%2Ffasthttpd","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffasthttpd%2Ffasthttpd","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffasthttpd%2Ffasthttpd/lists"}