How to use the UUID generator
- Five fresh UUIDs appear as soon as the page loads. Click Copy to copy them, one per line.
- Set How many from 1 to 500. A new batch is generated immediately.
- Switch Uppercase or Hyphens to match the format your system expects. The same UUIDs are reformatted, not replaced.
- Click Generate for a new batch, or Download .txt to save the list as a text file.
What is a UUID?
A UUID (universally unique identifier), also called a GUID, is a 128-bit number used to label records, files, devices and messages without asking a central server for the next free ID. It is written as 32 hexadecimal digits in five groups: 8-4-4-4-12, for 36 characters in total.
This tool creates version 4 UUIDs, the random kind defined in RFC 9562. Of the 128 bits, 6 are fixed to mark the version and variant and the other 122 bits are random. They come from your browser's cryptographically secure generator: crypto.randomUUID(), or crypto.getRandomValues() with the version bits set by hand on pages where randomUUID is not available. Nothing is generated on a server, and nothing is logged.
Reading a UUID: worked example
Take 3f2504e0-4f89-41d3-9a0c-0305e82c3301. The first digit of the third group is 4: this is the version. The first digit of the fourth group is 9; in binary 1001, it starts with the bits 10, which mark the standard variant. In every version 4 UUID that digit is 8, 9, a or b. Everything else is random. Without hyphens the same value is the 32-character 3f2504e04f8941d39a0c0305e82c3301.
How unique is unique?
With 122 random bits there are about 5.3 × 10³⁶ possible UUIDs. By the birthday paradox you would need to create about 2.7 × 10¹⁸ of them before the chance of even one duplicate reached 50%. If you generated one billion UUIDs, the probability that any two match would be roughly 1 in 10¹⁹, far smaller than the chance of a hardware error corrupting the data. That is why distributed systems can create IDs independently and merge them safely.
Tips for developers
- Database keys: random v4 UUIDs scatter inserts across an index. For large tables consider version 7, which starts with a timestamp and keeps new rows close together.
- Storage: store UUIDs in a native
uuidcolumn (PostgreSQL) or as 16 bytes (BINARY(16)) rather than a 36-character string to save space. - Comparison: treat UUIDs as case-insensitive; the standard prints them in lowercase.
- Not a password: UUIDs are unpredictable here, but they often end up in URLs and logs. Use a dedicated random token for secrets such as password-reset links.
- Test data: generate a batch of 500, download the .txt file and import it into a spreadsheet or seed script.
Frequently asked questions
What is the difference between a UUID and a GUID?
None in practice. GUID (globally unique identifier) is Microsoft's name for the same 128-bit format. A version 4 UUID from this tool works anywhere a GUID is expected.
Can two generated UUIDs ever be the same?
In theory yes, in practice no. A version 4 UUID has 122 random bits; you would need to generate about 2.7 quintillion of them to reach a 50% chance of a single duplicate.
Are these UUIDs secure enough for tokens?
They come from the browser's cryptographically secure random generator, so they are unpredictable. For session or password-reset tokens, a dedicated random token of 128 bits or more is still the better choice.
Should I use uppercase or lowercase?
The standard prints UUIDs in lowercase and says they should be compared without regard to case. Use uppercase only if a system, such as some Windows tools, expects it.