Generate UUIDs for Developers and Databases
What It Is
A UUID (Universally Unique Identifier) is a 128-bit identifier standardized by RFC 4122. This tool generates v1 (time-based), v4 (random), and v3/v5 (name-based) UUIDs.
Frequently Asked Questions
Q:What is the difference between UUID v1, v3, v4, and v5?
UUID v1 is time-based and includes the MAC address. UUID v4 is random and most commonly used. UUID v3 and v5 are name-based (MD5 and SHA-1 respectively) - they generate the same UUID for the same input name, making them deterministic.
Q:Are generated UUIDs truly unique?
UUID v4 (random) has a negligible collision probability (1 in 2^122). UUID v1 includes timestamp and MAC address for guaranteed uniqueness. UUID v3/v5 are deterministic - the same name always produces the same UUID within a namespace.
Q:Do my inputs get sent to a server when generating UUIDs?
No. All UUID generation happens client-side using the uuid library. Your input names, namespaces, and generated UUIDs never leave your browser.
Q:When should I use UUID v3 vs v5 for name-based generation?
UUID v3 uses MD5 hashing and UUID v5 uses SHA-1 hashing. v5 is recommended over v3 because SHA-1 is more secure than MD5 for most purposes. Both produce the same UUID for the same namespace and name combination.
Q:Can I use UUIDs as database primary keys?
Yes, but be aware that UUID v1 and v4 can impact B-tree index performance compared to auto-increment integers, especially on large tables. UUID v7 is emerging as a better alternative for database indexing.