PHP 8.4.1 · Native host · OPcache enabled

Router performance changes with the workload.

Seven PHP routing libraries, one deterministic dataset, equivalent handlers, explicit unsupported features, and raw results anyone can inspect or reproduce.

Normalized full dispatch

Different table sizes, different leaders

Full dispatch includes parameter extraction and equivalent handler invocation. Requests per second are single-process routing-operation estimates, not HTTP server throughput.

Small tables · 10/100 routes FastRoute

Lowest geometric-mean relative latency for the small-table group, narrowly ahead of Symfony Routing.

Heavy tables · 1,000/10,000 routes Ariel Radix Router

Lowest geometric-mean relative latency for the heavy-table group, followed by Symfony Routing.

Full dispatch · all four sizes Ariel Radix Router

Lowest geometric-mean relative latency across 10, 100, 1,000 and 10,000 routes for this scenario only.

RoutesLowest mean timeMean ns/opEstimated requests/s
10FastRoute1,772.4564,193
100Symfony Routing2,180.9458,529
1,000Symfony Routing2,508.0398,724
10,000Ariel Radix Router2,543.6393,150
Separate metric families

Cache, lifecycle, and memory tell different stories

Cache generation & load averageFastRoute

Lowest four-size aggregate among routers with a documented compiled-cache lifecycle.

Subsequent cached dispatch averageSymfony Routing

Lowest four-size aggregate after native cache loading and first dispatch.

Peak memory · 10/100 routesFastRoute

Lowest isolated-process peak for the two small route-table sizes.

Peak memory · 1,000/10,000 routesAltoRouter

Lowest isolated-process peak for the two larger route-table sizes.

Audit boundaries

Correctness before performance

Equivalent behaviorShared route IDs, parameters, methods, constraints, handlers, and adapter contract tests.
Separated costsRegistration, compilation, cold start, warm match, dispatch, cache, and memory are never blended.
Reproducible inputsFixed seed 19890717 and deterministic 10, 100, 1,000, and 10,000-route datasets.

Conflict-of-interest disclosure: the benchmark author also maintains Ariel Radix Router. Shared datasets, contract tests, raw exports, exact package commits, and reproducible commands are provided so readers can audit both methodology and implementation.