Skip to content
C

UUID (Universally Unique Identifier)

A 128-bit identifier designed so that, in practice, no two are ever the same.

Also called: guid

UUIDs are written as 32 hexadecimal characters in the form xxxxxxxx-xxxx-Mxxx-Nxxx-xxxxxxxxxxxx. The 'M' nibble encodes the version; 'N' encodes the variant.

Version 4 is random β€” used everywhere database keys need to be generated client-side without coordination. Version 7 (newer) embeds a Unix timestamp prefix so IDs sort lexicographically by creation time, which database indexes love.