UUID Generator
Generate UUID v4 and v7 right in your browser — nothing is sent to a server.
Press “Generate” to create UUIDs.
What is a UUID
A UUID (Universally Unique Identifier) is a 128-bit identifier used to uniquely distinguish entities — database records, files, messages, sessions — with no central authority handing out numbers. It is written as 32 hexadecimal digits in five dash-separated groups, for example 550e8400-e29b-41d4-a716-446655440000. The format is defined by RFC 9562, which updates the original RFC 4122.
Version 4 is fully random: 122 of the 128 bits come from a cryptographic random number generator. The collision probability is negligible in practice, which makes v4 UUIDs ideal as keys that reveal nothing about creation order or content.
Version 7 places a Unix millisecond timestamp in the first 48 bits, followed by random bits. The result is a time-ordered identifier: two v7 UUIDs created at different moments keep their chronological order even when compared as plain strings. That makes them excellent database primary keys, improving index locality compared to purely random UUIDs. This tool generates both versions entirely in your browser via the Web Crypto API: no value is ever sent to a server.
In practice, UUIDs are used anywhere you need a unique identifier generated in a distributed way, without coordinating multiple systems or instances: database primary keys, request IDs for log tracing, idempotency keys for payment APIs, session identifiers, filenames for user uploads. Unlike an auto-incrementing counter, a UUID can be generated client-side, offline, or in parallel by thousands of servers with no risk of collision and no need to query a database for the next value.
A common choice is between UUID v4 and auto-incrementing keys: the latter are more compact and very fast to index, but they reveal how many rows exist and in what order they were created, and require a single point of generation. UUID v4 solves those problems but, being random, degrades B-tree index performance on very large tables, since each insert lands at a random position in the tree. UUID v7 exists precisely for this: by preserving time ordering, inserts stay close together in the index, giving you the best of both worlds. Versions 1, 3 and 5 also exist (based on MAC addresses or hashes), but are less common today — this tool focuses on v4 and v7, the most common choices for modern applications. It's also worth knowing about the special all-zero "nil" UUID (00000000-0000-0000-0000-000000000000), defined by the same standard and sometimes used as a sentinel value meaning "no ID" rather than an actual identifier.
Frequently asked questions
- Are UUIDs generated on a server?
- No. Generation happens entirely in your browser via the crypto.getRandomValues API. No UUID is transmitted or stored — after the page first loads you can even use the tool offline.
- What is the difference between UUID v4 and v7?
- v4 UUIDs are fully random and carry no information about when they were created. v7 UUIDs embed a millisecond timestamp at the start, so they are chronologically sortable and more efficient as database primary keys.
- Are UUIDs guaranteed to be unique?
- Not in an absolute mathematical sense, but the probability of generating two identical UUIDs is so low it is negligible: you would need billions of UUIDs per second for many years before a real chance of collision.