UUID Generator

Generate random v4, time-ordered v7 or name-based v5 UUIDs with the Web Crypto API, or paste a UUID to see its version, variant and embedded timestamp.

Version

122 random bits. The general-purpose default.

0 UUIDsversion 4 · RFC 9562

Generating…

What this UUID generator does

A UUID (universally unique identifier) is a 128-bit value written as 32 hexadecimal digits in five groups, such as 550e8400-e29b-41d4-a716-446655440000. Because each one can be created independently with a negligible chance of collision, UUIDs are used as database keys, request IDs, file names and message IDs in systems where no central counter is available.

The format is defined by RFC 9562, published in May 2024, which obsoletes the older RFC 4122 and adds versions 6, 7 and 8. This tool generates the versions you are most likely to need (v4, v7 and v5, plus the Nil UUID) and includes an inspector that tells you what kind of UUID you are looking at.

How to use it

  1. Choose a Version: v4 random, v7 time-ordered, v5 name-based or Nil.
  2. For v4 and v7, set How many (1–1000). For v5, pick a Namespace (DNS, URL, OID, X500 or a custom UUID) and type the Name.
  3. Adjust the format: Case, Hyphens and {Braces} for the Microsoft registry style.
  4. Click Generate. Copy one value with its Copy button, or use Copy all / Download .txt for the whole list (one UUID per line).
  5. To check an existing value, open Validate / inspect and paste it. You will see its canonical form, version, variant and, for v1, v6 and v7, the timestamp it contains.

Worked examples

v5 is deterministic. With the DNS namespace and the name www.example.com, the generator always returns:

2ed6657d-e927-568b-95e1-2665a8aea6a2

Any correct v5 implementation (Python's uuid.uuid5(uuid.NAMESPACE_DNS, "www.example.com"), the npm uuid package and so on) produces the same value, so you can use it to cross-check other code.

v7 carries its creation time. A v7 UUID generated at 2026-11-09 12:00:00 UTC starts with 01a1c02d-f600, which is 1794225600000 milliseconds in hex. Pasting such a value into the inspector shows Version 7, Variant RFC 9562 / RFC 4122 (10xx) and Timestamp (UTC) 2026-11-09T12:00:00.000Z. The remaining digits are a counter and random bits, so they differ every time.

Which version to pick

  • v4 (random) — 122 random bits from the operating system's secure random generator. It reveals nothing about when or where it was made, which makes it the safe general-purpose choice and a reasonable public identifier.
  • v7 (time-ordered) — a 48-bit Unix timestamp in milliseconds, then the version, a 12-bit counter and 62 random bits. Values generated later sort later, so inserts into a primary-key index stay sequential. When you generate a batch within the same millisecond, this tool increments the counter so the list is strictly increasing.
  • v5 (name-based, SHA-1) — the same namespace and name always yield the same UUID. Use it for idempotent imports or to map external keys to UUIDs. It is not a way to hide the name: anyone who can guess the name can recompute it.
  • Nil — 00000000-0000-0000-0000-000000000000, a defined placeholder for "no UUID".

The inspector also understands v1 and v6 (Gregorian timestamp with a node ID), v3 (MD5 name-based) and v8 (custom layout), and it reports non-RFC variants such as old Microsoft GUIDs.

Limitations

  • Versions 1, 3, 6 and 8 can be inspected but not generated. v1 and v6 embed a node ID that is traditionally a MAC address, and v3 uses MD5; v7 and v5 are their modern replacements.
  • The v7 timestamp comes from your computer's clock. If the clock is wrong, the embedded time is wrong too.
  • The monotonic counter only applies within one batch on this page; UUIDs created on different machines in the same millisecond are unique but not ordered relative to each other.
  • v5 needs crypto.subtle, which browsers only expose on HTTPS pages (this site is served over HTTPS).

Tips and common mistakes

  • Store UUIDs as binary or a native type. PostgreSQL has a uuid type; in MySQL use BINARY(16) rather than a 36-character string to halve the index size.
  • Compare case-insensitively. RFC 9562 says UUIDs are output in lowercase but must be accepted in either case.
  • Don't treat UUIDs as secrets. v4 values are unpredictable, but a password-reset or session token should be generated as a token, not borrowed from an ID column. Use the Password Generator or the Hash Generator for those jobs.
  • v7 exposes creation time. If knowing when a record was created would leak information (for example, sign-up dates in a public user ID), use v4 instead.

Frequently Asked Questions

Should I use UUID v4 or v7?

Use v7 for database primary keys and anything you want to sort by creation time: its first 48 bits are a millisecond timestamp, so new rows land at the end of a B-tree index instead of at random positions. Use v4 when the ID must not reveal when it was created.

Can two generated UUIDs collide?

In practice, no. A v4 UUID has 122 random bits, so you would need to generate around 2.7 × 10^18 of them before the chance of a single duplicate reaches 50%. A v7 UUID has 74 random-or-counter bits per millisecond, which is still far beyond any realistic generation rate.

What is a v5 UUID and when is it useful?

A v5 UUID is the SHA-1 hash of a namespace UUID plus a name, formatted as a UUID. The same namespace and name always produce the same value, which is handy for deriving stable IDs from URLs, domain names or external keys without storing a mapping.

What is the difference between a UUID and a GUID?

They are the same 128-bit format. UUID is the IETF name (RFC 9562, which replaced RFC 4122 in 2024); GUID is Microsoft's name in COM and .NET. Microsoft tools often display GUIDs in uppercase and inside braces, which this tool can also output.

Can I tell when a UUID was created?

Only for time-based versions. Paste a v1, v6 or v7 UUID into the Validate / inspect tab to read its embedded timestamp. Versions 4 and 5 contain no time information.

Are the UUIDs generated on your server?

No. Every UUID is created in your browser with the Web Crypto API (crypto.getRandomValues, crypto.randomUUID and crypto.subtle for SHA-1). Nothing is sent to or stored on our servers.