UUID / GUID Generator
Generate UUIDs in v1, v4, or v5 — bulk, formatted, with optional prefix/suffix.
Version Reference
v4 — Random
Version 4 UUIDs are generated entirely from random (or pseudo-random) bytes. 122 of the 128 bits are random; the remaining 6 bits encode the version (4) and the variant. Because they carry no structured information, v4 UUIDs are the simplest choice: they require no shared state, no network clock, and no namespace coordination. The probability of generating a duplicate is astronomically low. Use v4 as the default for database primary keys, session tokens, and any context where uniqueness is required but time ordering is not.
Wikipedia — UUID Version 4 (random)
v1 — Time-based
Version 1 UUIDs embed a 60-bit timestamp (100-nanosecond intervals since 15 October 1582, the Gregorian calendar reform date), a 14-bit clock sequence, and a 48-bit node identifier (historically the MAC address of the generating machine). Because the timestamp is the most-significant component, v1 UUIDs sort chronologically when compared lexicographically — a useful property for clustered database indexes. The trade-off is privacy: a v1 UUID leaks the machine's MAC address and the exact creation time. Modern implementations substitute a random node to avoid that exposure.
Wikipedia — UUID Version 1 (time-based)
v5 — Namespace + Name (SHA-1)
Version 5 UUIDs are deterministic: given the same namespace UUID and the same name string, the output is always identical. The algorithm concatenates the namespace bytes and the UTF-8 encoded name, hashes them with SHA-1, then folds the 160-bit digest into 128 bits (setting version bits to 5 and the RFC 4122 variant). This makes v5 ideal for generating stable, reproducible identifiers — for example, mapping a URL to a UUID that never changes, or converting a legacy string key into a UUID without a lookup table. v3 uses MD5 instead; v5 is preferred because SHA-1 produces fewer collisions.