Run it
Limits and measurements
What one shard holds, how fast writes and reads went, and the conditions behind each number. Measured on production in November 2026, on one account.
SET/s on 16 shards
Through the router, 8 load generatorsAfter aborting every shard
50,000 acknowledged writes, twiceTo new code after a deploy
With no failed commandsMost numbers come from the bench API, which runs its clients inside Cloudflare: load generators through the router, Sender objects in each of the nine regions, or straight to one shard. Latency over TCP came from one laptop on a home connection.
Limits
| Limit | Value | Why |
|---|---|---|
| Data per shard | 64 MB | Valkey's data lives in wasm memory, inside a 128 MB memory limit |
| Request size | About 8 MB; 64 KB before AUTH | A shard holds the query, the value and its AOF entry |
| CPU | One thread per shard; about 30 s per command | An object kept near 100% CPU is reset |
| Writes per shard | 114-130k SET/s, deep pipelines | A shard runs on one thread |
| With 9 replicas | 49-61k SET/s per shard | Replication streams hold back the primary's input |
| Size, regions, replicas | Fixed at creation | Routing is computed from the catalog record |
| Replica reads | Up to one replication lag stale | Only on other connections |
Memory
The 64 MB limit counts Valkey's used_memory. The memory limit counts wasm linear memory, which measured 1.08 to 1.29 times used_memory with the build's allocator, flat across rounds of deleting and rewriting half the keys.
Linear memory never shrinks: after deleting data from 39 MB to 9 MB, it stayed at 44 MB. With noeviction, writes past the limit get OOM; with allkeys-lru the shard evicts like a cache.
Throughput
| Load | Result |
|---|---|
| Deep pipelines straight to one shard | 114-130k SET/s, 250-306k GET/s |
| 16 shards through the router, 8 load generators | 255-304k SET/s with group commit, 48-66k before it |
| Rows written per write, under that load | About 0.008 with group commit, 0.26 before it |
| 64 shards, 640 connections, 1-byte values | 219k SET/s in a burst of tens of seconds, 0 errors |
| 200 connections over 16 shards | 20-26k ops/s: past the socket budget, on batched calls |
Bursts, not a sustained ceiling. From a single laptop over TCP, throughput is bound by its round trips: valkey-benchmark with 200 connections and 64-deep pipelines reached 45.5k SET/s on one shard.
Latency
| Command | p50 | p99 |
|---|---|---|
| PING, answered by the router | 10-12 ms | 40 ms |
| GET | 54 ms | 95 ms |
| SET | 57-60 ms | 173-330 ms |
| Connect, AUTH, PING | 85 ms | 211 ms (p90) |
One TCP connection through Spectrum, one command at a time, shards 15 to 45 ms from the router. Nearly everything past the first 10 ms is the Worker's hop to the shard. A write adds one storage commit, which measured 10 to 38 ms p50 from inside a shard, depending on its region.
Replicas
| Check, replicas in all nine regions | Result |
|---|---|
| Every replica serving after the database was created | Within seconds |
| A second client reads a write acknowledged to the first | p50 3-41 ms, p99 38-141 ms |
| Keys written, then read back from every region | 20,000 of 20,000 |
| Read-your-writes on one connection | 0 stale in 2,700 checks |
| WAIT 9 after writes to 3 shards | About 0.9 s, the slowest replica's round trip |
| Replica GET p99 while its primary rewrote under load | 45 ms, against a primary max of 318-1117 ms |
Rewrites
| 35.6 MB base | Time | PINGs during it |
|---|---|---|
| Inline | 1.4-1.9 s | Blocked for the whole rewrite |
| In a rewriter | 5.2-5.9 s end to end | p99 128-175 ms |
| 16 shards rewriting at once, under writes | Slowest 1.42 s | All ran in rewriters |
| 300,000 writes across a rewrite, then a restart | 0 missing | Also with replicas in 2 regions |
Cold starts and deploys
| Event | Valkey | Redis |
|---|---|---|
| First SET on a new database | 486-648 ms | 512-642 ms |
| Next SET | 49-62 ms | 50-66 ms |
| First GET after an abort, 16 MB of data | 75-395 ms | 161-293 ms |
| First GET after an abort, 56 MB of data | 79-353 ms | 146-316 ms |
| Deploy under load | Result |
|---|---|
| Shards on the new code | 10-25 s after the deploy |
| Commands that failed | None |
| Slowest reply | Under 1 s |
| Replicas on the new code and serving | Within 35 s |
| Counters checked at the end | All correct |
Failure tests
| Test | Result |
|---|---|
| 50,000 acknowledged writes, then every shard aborted | 0 missing |
| test/hammer.mjs with CHAOS=1 | 11 of 11 invariants held through 35 shard aborts |
| Connection churn: connect, AUTH, write, read, close | 6,995 of 7,000 connections |
| test/differential.mjs, 1 shard against N | Identical replies |
| 36 replicas, 20,000 keys | All read back in each of 9 regions |