UUID Generator
Version 4, from the browser random source. Nothing is sent or stored.
Made here, kept nowhere. Reload and these are gone.
How to use
- Choose how many you need and press Generate.
- Copy takes one; Copy all takes the list, one per line.
- Turn hyphens off for a 32-character form, or capitals on if your system wants them.
Examples
A primary key before the row exists
A v4 UUID can be made in the client, which is what makes it useful: the record can carry its id before it reaches the database, and two clients will not collide.
A correlation id for a log line
One id threaded through a request makes a trace searchable. The hyphen-free form is easier to grep and easier to paste into a URL.
A test fixture
0f8fad5b-d9cb-469f-a165-70867728950e is the kind of value tests paste in. Generate twenty at once and keep them in the fixture file.
Not a password
A UUID is unique, not secret — it is often logged and often public. For something that has to stay secret, use the password generator. Password Generator
FAQ
Where does the randomness come from?
crypto.getRandomValues, the browser cryptographic random source. Math.random is not used. getRandomValues rather than crypto.randomUUID because the latter needs a secure context and is missing on older browsers, and this way the version and variant bits can be tested on known input.
Is anything sent to a server?
No. The ids are made in the page and nothing is uploaded, logged or stored.
What does "version 4" mean?
122 of the 128 bits are random; the other six say which version and variant this is. That is why every id here has a 4 at the start of the third group and one of 8, 9, a or b at the start of the fourth.
Can two of them ever be the same?
Not in practice. With 122 random bits, generating a billion a second for about 85 years gives you roughly a coin-flip chance of one duplicate anywhere in the lot. Stop a long way short of that and the chance stays negligible.
Why would I remove the hyphens?
Some systems store a UUID as 32 hex characters or as 16 bytes, and some URLs read better without them. The value is the same either way — put them back and it is still the same id.
Is uppercase a different id?
No. Hex is case-insensitive here, so the same id can be written either way. Lowercase is the canonical form in RFC 4122 and what most systems compare against.