Why UUIDs are Secretly Incredibly Fascinating
summary
UUIDs are decoded into actual designs not just vague topics: uuid v7 is 48 bits of Unix milliseconds then random bits and is monotonic with clock jitter handling, uuid v6 is v1 with time bits reordered for index locality, uuid v8 is a vendor‑defined 128‑bit layout, uuid v5 deterministically hashes a namespace and name via SHA‑1. Random v4 collisions are astronomically unlikely but real collisions come from bad entropy. Practical advice: store UUIDs as binary/native types in Postgres, prefer v7 for sortable distributed IDs, and avoid 32‑bit primary keys.
AI-written summary · about
chapters (15)
- 0:00Introduction
- 1:28UUIDs in real-world use
- 3:14UUIDs in Django & DB keys
- 5:00UUID history & limitations
- 7:48UUIDv1 structure deep dive
- 10:53UUIDv3 & v5 deterministic IDs
- 13:25UUIDv4 collision probabilities
- 15:15Sequential IDs vs UUIDs
- 17:00Twitter & MongoDB ID design
- 19:27UUIDv6 & v7 explained
- 21:54UUIDv8 & custom IDs
- 23:17UUIDs as DB primary keys
- 26:10Storing UUIDs best practices
- 27:36Inventing custom UUID variants
- 27:56Final advice on primary keys








