UUID Generator
Generate cryptographically random v4 UUIDs, one at a time or in bulk.
fcd203c0-7155-472c-9cbd-d7fcc76ad7df46788a7c-26f1-4d54-9222-e2b204de008c84f9aa2c-87e4-42f6-9ee1-cae4f177e26ddd177625-829b-480a-b175-def9f23adf68b9bcc092-72a8-4e3c-8bcd-65ff145d81d9
How to use this tool
Choose how many UUIDs you need, from 1 to 50, and generate. Copy one with its own button, or use Copy all to get the whole batch with one UUID per line, ready to paste into a spreadsheet column or a seed file. They come from the browser's crypto.randomUUID(), the same cryptographic random source used for keys.
Reading a version 4 UUID
In f47ac10b-58cc-4372-a567-0e02b2c3d479, two digits are fixed and the other 122 bits are random:
- The first digit of the third group is always 4, the version.
- The first digit of the fourth group is always 8, 9, a or b, the variant that marks a standard RFC 9562 UUID.
So every UUID from this page matches ^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$, a check worth adding when your code accepts UUIDs from outside. A value with a different digit in either position came from another UUID version, or isn't a UUID.
Storing them
- PostgreSQL has a
uuidcolumn type that stores the 16 bytes and accepts the text form in upper or lower case. - MySQL has no UUID type:
CHAR(36)stores the text, 36 bytes per value, whileBINARY(16)withUUID_TO_BIN()stores the same value in 16. - Compare UUIDs case-insensitively or store them in lower case. This page, crypto.randomUUID(), Python's uuid module and Java's UUID class all write lower case, as RFC 9562 specifies, but Windows tools such as the Registry Editor show GUIDs in upper case, inside braces.
Frequently Asked Questions
How likely is a UUID collision — could two ever be the same?
Possible in principle, negligible in practice. A v4 UUID has 122 random bits, so there are about 5.3 × 10^36 possible values. By the birthday bound, a set of one billion UUIDs has roughly a 1 in 10^19 chance of containing any duplicate. You would need about 2.7 × 10^18 of them for a 50% chance, which at a billion a second takes around 86 years. The real risk is a weak random source, not the arithmetic: this page uses the browser's cryptographic generator.
Can I use these as passwords or secret tokens?
They are generated from a cryptographic source, but UUIDs are made to be identifiers, and they tend to end up in URLs, logs and support tickets. For a secret, generate a token meant to stay secret, such as 32 random bytes from your language's secure random function, and store only its hash.
Why does this page only make version 4?
Because crypto.randomUUID() produces version 4, and it is the right default for most IDs. If you need IDs that sort by creation time, for example as a database primary key, version 7 puts a timestamp in the first 48 bits; the UUID guide on this site explains the difference.
Related Tools
Related Blog Posts
Understanding UUIDs — What They Are and Why Developers Use Them
Why UUIDs are used instead of auto-incrementing IDs, what the version number means, and when a UUID is (or isn't) the right choice.
Read moreHow to Use QR Codes for Marketing, Docs, and Events
How much a QR code can hold, why a shorter or uppercase link gives a code that scans more easily, what error correction actually protects against, and how to size one for print.
Read moreHEX, RGB and HSL: How the Conversions Work and Where They Round
#4F46E5 converted to RGB and HSL step by step, why 89.4% of all colours change when copied as whole-number HSL, why HSL lightness is not brightness (yellow and blue at 50% differ eightfold in contrast), and the alpha that hex can't write exactly.
Read more