UUID Generator
Generate random UUID v4 or time-ordered UUID v7 identifiers — also known as GUIDs — one at a time or up to 500 in bulk, from your browser's cryptographically secure random source. Switch hyphens, case and braces without regenerating the values.
Generated UUIDs (0)
UUID v4 is 122 random bits from the browser's cryptographic generator (crypto.getRandomValues), with the version and variant bits set as RFC 9562 requires.
UUID v7 opens with a 48-bit Unix millisecond timestamp and a counter, then 62 random bits, so a batch sorts in the order it was generated — the better fit for database keys.
Frequently asked questions
What is a UUID v4?
A 128-bit identifier whose bits are random apart from six that mark the version and variant, written as 32 hexadecimal digits in five hyphen-separated groups. Because it needs no central authority to hand it out, any machine can mint one that will not collide with anyone else’s.
What is a UUID v7, and when should I pick it over v4?
A v7 UUID starts with a 48-bit Unix millisecond timestamp, followed by a counter and 62 random bits, so a batch sorts in the order it was created and a v7 value is still unguessable. Pick v7 for database keys and anything stored in time order — inserts land at the end of an index instead of all over it — and v4 when the time of creation should not be readable from the identifier.
Is a GUID the same thing as a UUID?
Yes, in practice. GUID is Microsoft’s name for the same 128-bit identifier, and the two terms are interchangeable across .NET, SQL Server and the wider ecosystem. The only differences you will meet are cosmetic: some Microsoft tooling shows them in upper case or wrapped in braces, both of which are format options here.
Are random UUIDs really unique?
For every practical purpose, yes. A v4 UUID has 122 random bits, and you would need to generate on the order of a billion a second for about 85 years before a single collision became likely. The real risk is not the mathematics but a weak random source, which is why these come from your browser’s cryptographic generator.
Can I generate several UUIDs at once?
Yes — set the count and up to five hundred are produced together, with a button to copy the whole list one per line. That is the usual shape for seeding a fixtures file or filling a column of test rows. Changing the format afterwards only re-lays-out the same values, so you can copy them with and without hyphens.
Should I use a UUID as a database primary key?
It is a reasonable choice when IDs must be generated by clients, across shards or offline, and it avoids leaking a row count the way a sequential integer does. The costs are a wider key and, for v4, random insert order that fragments a clustered index — which is what the time-ordered UUID v7 offered here was designed to fix.
Are the UUIDs generated on a server?
No. They are produced in your browser from crypto.getRandomValues, so the values never exist anywhere else and nothing is transmitted. That also means the same UUID can never be handed to two visitors.
