bun
Flagship · TS · standard configuration · completeness 3/4
Bun.serve, Bun's own HTTP server, with no framework on top and one process per core sharing the ports. The same routes serve every protocol: HTTP/1.1 on 8080 and over TLS on 8081, h2c on 8082 and h2 plus HTTP/3 on 8443 through Bun's experimental `http2: true` and `http3: true` flags (QUIC is Bun's own lsquic, no proxy in front).
Achievements
🥇 9 Gold · 🥈 1 Silver · 🥉 3 Bronze. Top three of a field, taken in this entry's own league: the family composite, the same composite among entries written in the same language, and each test profile it is scored on. Every field is the one the badges publish, so a medal and a badge always say the same thing. How medals are awarded.
| Medal | Award | Field | Rank |
|---|---|---|---|
| 🥇 Gold | Family composite | Composite · HTTP/2 | 1 of 18 |
| 🥇 Gold | Family composite | Composite · HTTP/3 | 1 of 7 |
| 🥇 Gold | Within its language | TS · HTTP/1.1 | 1 of 4 |
| 🥇 Gold | Test profile | HTTP/2 · Baseline | 1 of 17 |
| 🥇 Gold | Test profile | HTTP/2 · Baseline (h2c) | 1 of 14 |
| 🥇 Gold | Test profile | HTTP/2 · JSON (h2c) | 1 of 14 |
| 🥇 Gold | Test profile | HTTP/3 · Baseline | 1 of 7 |
| 🥇 Gold | Test profile | HTTP/3 · Static | 1 of 7 |
| 🥇 Gold | Test profile | Workload · JSON Comp | 1 of 68 |
| 🥈 Silver | Test profile | HTTP/2 · Static | 2 of 16 |
| 🥉 Bronze | Family composite | Composite · HTTP/1.1 | 3 of 71 |
| 🥉 Bronze | Test profile | Concurrency · Async Delay | 3 of 67 |
| 🥉 Bronze | Test profile | Workload · JSON TLS | 3 of 66 |
Composite rank
Each profile of a family is worth 100 to the entry that leads it, and the composite is the sum over the family, less 2.5% for each of routing, middleware, request and response the entry does not do for you - its completeness factor, which the WebSocket and gRPC families do not carry. The field is this entry's own league: engines and reverse proxies are scored apart from frameworks. How it works.
| Family | Rank | Composite |
|---|---|---|
| HTTP/1.1 | 3 of 71 | 6065 |
| HTTP/2 | 1 of 18 | 3362 |
| HTTP/3 | 1 of 7 | 1950 |
Every result
Alpha Round, 25 runs. Requests per second is the best of three; latency, CPU and memory come from that run.
| Category | Profile | Conns | Req/sec | Avg | p99 | CPU | Memory |
|---|---|---|---|---|---|---|---|
| Connection | Baseline | 4,096 | 1,926,386 | 2.13ms | 3.84ms | 6737.0% | 1.2GiB |
| Connection | Pipelined | 4,096 | 5,529,928 | 11.85ms | 15.20ms | 6393.6% | 328MiB |
| Connection | Short-lived | 4,096 | 1,672,444 | 2.43ms | 8.61ms | 6283.0% | 1.1GiB |
| Concurrency | Async Delay | 32,000 | 1,949,532 | 16.33ms | 22.30ms | 6385.5% | 1.5GiB |
| Efficiency | Latency-10K | 1,024 | 9,982 | 82.4us | 125.0us | 54.0% | 394MiB |
| Efficiency | Latency-1M | 1,024 | 997,935 | 140.7us | 429.0us | 4730.8% | 967MiB |
| Efficiency | Latency-500K/8 | 1,024 | 337,393 | 3193429.7us | 7223296.0us | 782.5% | 181MiB |
| Workload | JSON Comp | 4,096 | 460,716 | 8.87ms | 20.90ms | 6322.9% | 1.1GiB |
| Workload | JSON Comp | 16,384 | 460,816 | 35.22ms | 61.00ms | 6179.2% | 1.1GiB |
| Workload | JSON TLS | 4,096 | 1,081,708 | 3.80ms | 41.48ms | 6292.0% | 966MiB |
| Workload | 8Gbit | 512 | 49,237 | 105.5us | 180.0us | 397.7% | 476MiB |
| Workload | Static TLS | 1,024 | 481,407 | 2.28ms | 62.40ms | 6530.9% | 1.0GiB |
| Database | Async DB | 1,024 | 283,049 | 3.07ms | 15.90ms | 5120.9% | 2.1GiB |
| Database | Fortunes | 1,024 | 82,408 | 8.97ms | 24.00ms | 6416.8% | 1.9GiB |
| HTTP/2 | Baseline | 256 | 7,062,166 | 3.54ms | 20.48ms | 6283.7% | 1.2GiB |
| HTTP/2 | Baseline | 1,024 | 7,059,841 | 13.46ms | 84.78ms | 6272.8% | 1.3GiB |
| HTTP/2 | Static | 256 | 613,748 | 14.32ms | 87.71ms | 6332.3% | 1.2GiB |
| HTTP/2 | Static | 1,024 | 599,957 | 51.83ms | 249.17ms | 6387.3% | 1.4GiB |
| HTTP/2 | Baseline (h2c) | 256 | 7,306,785 | 3.59ms | 23.23ms | 6203.3% | 1.3GiB |
| HTTP/2 | Baseline (h2c) | 1,024 | 7,402,051 | 13.25ms | 53.30ms | 6388.6% | 1.3GiB |
| HTTP/2 | Baseline (h2c) | 4,096 | 7,262,661 | 52.79ms | 150.50ms | 6177.6% | 1.3GiB |
| HTTP/2 | JSON (h2c) | 1,024 | 2,245,990 | 14.67ms | 67.74ms | 6289.2% | 1.0GiB |
| HTTP/2 | JSON (h2c) | 4,096 | 2,218,793 | 56.52ms | 178.21ms | 6221.8% | 1.1GiB |
| HTTP/3 | Baseline | 64 | 3,435,034 | 1.04ms | 2.51ms | 3616.5% | 1.0GiB |
| HTTP/3 | Static | 64 | 289,587 | 14.81ms | 138.14ms | 5306.5% | 1.3GiB |
Compared with
The TS entries around bun on the HTTP/1.1 composite, and the one leading them. The last column shows every profile side by side.
| Entry | Composite | vs bun | |
|---|---|---|---|
| elysia | 4272 | -30% | head to head |
| hono-bun | 3327 | -45% | head to head |
Compare bun with any TS entry · Compare bun with any entry, in any language · Every TS entry, ranked
Results updated · How the benchmark is run · The machine · Add or fix an entry