Skip to content
Tools

Latency numbers every engineer should know

Fourteen operations from an L1 cache hit to a packet crossing the Atlantic, drawn on a scale where you can actually see the gaps. Flip the switch to rescale everything to human time, which is when the numbers stop being trivia and start being intuition.

Runs in your browser. Nothing is sent anywhere.

  1. L1 cache reference0.5 ns

    The fastest thing that is not already in a register.

  2. Branch mispredict5 ns

    The pipeline guessed wrong and has to throw away its work.

  3. L2 cache reference7 ns

    Fourteen times L1. This gap is why cache-friendly layouts win.

  4. Mutex lock and unlock25 ns

    Cheap uncontended. Contention is what actually costs you.

  5. Main memory reference100 ns

    200x L1. A cache miss is not a small event.

  6. Compress 1 KB with Zippy3 µs

    Often worth it. Compressing before a network hop usually pays.

  7. Send 1 KB over 1 Gbps network10 µs

    Bandwidth, not distance. Distance is the row at the bottom.

  8. Read 4 KB randomly from SSD150 µs

    1,500x main memory, and still a bargain next to a disk seek.

  9. Read 1 MB sequentially from memory250 µs

    Sequential access is where memory bandwidth shows up.

  10. Round trip in the same datacenter500 µs

    Half a millisecond. Multiply by every service you call in a chain.

  11. Read 1 MB sequentially from SSD1 ms

    4x reading the same megabyte from memory.

  12. Disk seek10 ms

    A spinning platter physically moving. 20,000x main memory.

  13. Read 1 MB sequentially from disk20 ms

    80x the same read from memory. Sequential still beats seeking.

  14. Packet from California to Netherlands and back150 ms

    Mostly the speed of light. No hardware upgrade will ever fix this.

Bars are on a log scale. The distance between the top row and the bottom row is nine orders of magnitude, which a linear chart cannot draw.

These are the canonical figures, the set that interviews and textbooks use. They are not benchmarks of 2026 hardware and were never meant to be. SSDs and networks have improved by roughly an order of magnitude since they were written down, and one row has not moved at all, because you cannot negotiate with the speed of light.

What you memorise is the ratios. Main memory is 200 times slower than L1. A disk seek is 20,000 times slower than main memory. A round trip across the planet is 300 times slower than a round trip inside one datacenter. Hold those three and you can predict where a slow system is spending its time before you have opened a profiler.

The practical version: every layer you cross costs about two orders of magnitude. Cache, then memory, then local disk, then the network next door, then the network across the world. A request that touches all five is not slow because of your code. It is slow because of where the data lives.