Lightweight, flexible HTTP server framework written in Swift
1,885
stars
1,034
commits
Swift
primary language
Sep 11, 2026
updated
Lightweight, flexible, modern server framework written in Swift.
Hummingbird is a lightweight, flexible modern web application framework that runs on top of a SwiftNIO based server implementation. It is designed to require the minimum number of dependencies.
It provides a router for directing different endpoints to their handlers, middleware for processing requests before they reach your handlers and processing the responses returned, custom encoding/decoding of requests/responses, TLS and HTTP2.
import Hummingbird
// create router and add a single GET /hello route
let router = Router()
router.get("hello") { request, _ -> String in
return "Hello"
}
// create application using router
let app = Application(
router: router,
configuration: .init(address: .hostname("127.0.0.1", port: 8080))
)
// run hummingbird application
try await app.runService()
Hummingbird's core is designed to be minimal, with additional features provided through extensions. Here are some official extensions:
HummingbirdRouter: An alternative router using result buildersHummingbirdTLS: TLS supportHummingbirdHTTP2: HTTP2 upgrade supportHummingbirdTesting: Helper functions for testing Hummingbird projectsThe following extensions are available in separate repositories:
You can find reference documentation and user guides for Hummingbird here. The hummingbird-examples repository has a number of examples of different uses of the library.
Add the following to your Package.swift file:
dependencies: [
.package(url: "https://github.com/hummingbird-project/hummingbird.git", from: "2.0.0")
],
targets: [
.executableTarget(
name: "MyApp",
dependencies: [
.product(name: "Hummingbird", package: "hummingbird"),
]),
]
Or run the following commands on your package using SwiftPM, replacing MyApp with the name of your target:
swift package add-dependency https://github.com/hummingbird-project/hummingbird.git --from 2.0.0
swift package add-target-dependency Hummingbird MyApp --package hummingbird
We welcome all contributions to Hummingbird!
Please read our contributing guidelines, before making a contribution to the project.
Support development of Hummingbird by becoming a sponsor.
Support development of Hummingbird by becoming a backer.





(top 30 of 38)
Swift
98.9%
Shell
1.0%
Lightweight, flexible HTTP server framework written in Swift
1,885
stars
1,034
commits
Swift
primary language
Sep 11, 2026
updated
Lightweight, flexible, modern server framework written in Swift.
Hummingbird is a lightweight, flexible modern web application framework that runs on top of a SwiftNIO based server implementation. It is designed to require the minimum number of dependencies.
It provides a router for directing different endpoints to their handlers, middleware for processing requests before they reach your handlers and processing the responses returned, custom encoding/decoding of requests/responses, TLS and HTTP2.
import Hummingbird
// create router and add a single GET /hello route
let router = Router()
router.get("hello") { request, _ -> String in
return "Hello"
}
// create application using router
let app = Application(
router: router,
configuration: .init(address: .hostname("127.0.0.1", port: 8080))
)
// run hummingbird application
try await app.runService()
Hummingbird's core is designed to be minimal, with additional features provided through extensions. Here are some official extensions:
HummingbirdRouter: An alternative router using result buildersHummingbirdTLS: TLS supportHummingbirdHTTP2: HTTP2 upgrade supportHummingbirdTesting: Helper functions for testing Hummingbird projectsThe following extensions are available in separate repositories:
You can find reference documentation and user guides for Hummingbird here. The hummingbird-examples repository has a number of examples of different uses of the library.
Add the following to your Package.swift file:
dependencies: [
.package(url: "https://github.com/hummingbird-project/hummingbird.git", from: "2.0.0")
],
targets: [
.executableTarget(
name: "MyApp",
dependencies: [
.product(name: "Hummingbird", package: "hummingbird"),
]),
]
Or run the following commands on your package using SwiftPM, replacing MyApp with the name of your target:
swift package add-dependency https://github.com/hummingbird-project/hummingbird.git --from 2.0.0
swift package add-target-dependency Hummingbird MyApp --package hummingbird
We welcome all contributions to Hummingbird!
Please read our contributing guidelines, before making a contribution to the project.
Support development of Hummingbird by becoming a sponsor.
Support development of Hummingbird by becoming a backer.





(top 30 of 38)
Swift
98.9%
Shell
1.0%