HttpArena

PHP web framework comparison: any two, head to head

swoole is ahead of hyperf on 12 of the 13 tests they both run, and behind on 1. On the HTTP/1.1 composite swoole scores 3175 and hyperf 1118.

Pick any two of the 5 PHP entries. Requests per second is the best of three runs and the delta is the first column against the second; every row is the same profile at the same connection count, on the same machine. The fixed-rate profiles offer every entry the same request rate, so they are compared on their score out of 100 instead, which is CPU cost and latency at that rate. What each profile measures.

ProfileConnsswoolehyperfDeltaswoole p99hyperf p99
Requests per second
Baseline4,0962,310,475387,711+496%9.83ms12.90ms
Pipelined4,0963,298,449466,686+607%44.50ms300.30ms
Short-lived4,0961,940,869294,276+560%10.00ms17.80ms
Async Delay32,00012,618303,908-96%5.00s121.20ms
JSON Comp4,096544,249242,307+125%35.00ms22.80ms
JSON Comp16,384539,064241,986+123%100.20ms47.10ms
JSON TLS4,096797,654199,611+300%111.38ms422.16ms
Echo5123,056,601431,538+608%3.04ms1.64ms
Echo4,0963,354,954429,659+681%6.79ms10.50ms
Echo16,3843,168,894414,613+664%13.70ms13.90ms
Fixed-rate profiles: score out of 100
Latency-10K1,02473.639.7+85%117us366us
Latency-1M1,02469.52.8+2382%210us13.67s
8Gbit51275.135.4+112%142us1.16ms

Common comparisons

swoole vs hyperf · swoole vs php-fpm · swoole vs true-async-server · hyperf vs php-fpm · hyperf vs true-async-server · php-fpm vs true-async-server

Questions

Is swoole faster than hyperf?

swoole is ahead of hyperf on 12 of the 13 tests they both run, and behind on 1. On the HTTP/1.1 composite swoole scores 3175 and hyperf 1118. Both run on the same machine, in the same round, against the same profiles.

Is swoole faster than php-fpm?

swoole is ahead of php-fpm on 11 of the 14 tests they both run, and behind on 3. On the HTTP/1.1 composite swoole scores 3175 and php-fpm 848. Both run on the same machine, in the same round, against the same profiles.

Is swoole faster than true-async-server?

swoole is ahead of true-async-server on 9 of the 14 tests they both run, and behind on 5. On the HTTP/1.1 composite swoole scores 3175 and true-async-server 3442. Both run on the same machine, in the same round, against the same profiles.

Is hyperf faster than php-fpm?

hyperf is ahead of php-fpm on 8 of the 10 tests they both run, and behind on 1. On the HTTP/1.1 composite hyperf scores 1118 and php-fpm 848. Both run on the same machine, in the same round, against the same profiles.

Which PHP framework is fastest overall?

true-async-server holds the highest HTTP/1.1 composite of the PHP web frameworks, at 3442. The composite is throughput over the whole suite; if a service is one shape of workload, compare that profile on its own in the table above, because the order changes.

Every PHP entry

Results updated · PHP composite ranking · Compare across languages · Other languages · Open the leaderboard