Generating identifiers

UUID text8 sectionsUpdated

The tool generates every layout anyone makes in practice (v1, v3, v4, v5, v6, v7 and v8), plus a ULID and the two constants. For the ones that carry a clock you can pick the moment; for the name-based ones you pick a namespace and a name.

Converting is only half of what the tool does. This page covers the other half: which generator to reach for, what each one puts in the bits, and the two options that only some of them take.

What the converter reads backcomputed by the converter itself
incfbff0d1-9375-5685-968c-48ce8b15ae17outuuid · RFC 9562 (10xx) · version 5

v5 of the DNS namespace and example.com

in9073926b-929f-31c2-abc9-fad77ae3e8eboutuuid · RFC 9562 (10xx) · version 3

v3 of the same pair

in00000000-0000-0000-0000-000000000000outuuid · NCS (0xxx) — reserved, backward compatibility · no version · nil, palindrome

Nil

inffffffff-ffff-ffff-ffff-ffffffffffffoutuuid · reserved for the future (111x) · no version · max, palindrome

Max

Open the converter: UUID textNothing you paste leaves the browser.
On this page (8)

What each generator gives you#

TypeMade ofTakes a momentTakes a name
v4122 random bitsnono
v748 bits of Unix ms, then randomnessyesno
v1a 1582 clock and a nodeyesno
v6the v1 clock, reordered to sortyesno
v3MD5 of a namespace and a namenoyes
v5SHA-1 of a namespace and a namenoyes
v8free bits, filled at random herenono
ULIDthe v7 clock in Crockford base32yesno
Nil, Maxall zeros, all onesnono

Version 2 is missing from that list on purpose: DCE Security identifiers need a POSIX user or group id, almost no library makes them, and the layout page covers what they contain if you have been handed one.

RFC 9562 § 5 · UUID LayoutsEvery layout the generators above follow

Aiming the clock#

v1, v6, v7 and ULID carry a timestamp, so the generator lets you set it. Leave the field empty and it uses now; type a date and you get an identifier that claims that moment. The field has no timezone, so the browser reads it as local time, which is what somebody typing 2024-05-03 01:09 into it means.

That is useful for fixtures, for reproducing a bug that only shows up around a boundary, and for testing a range query without waiting for the clock. It is not a way to backdate anything real: the identifier says what it was told to say.

Name-based generation, in one line#

Pick a namespace, type a name, and the identifier appears. The same pair always gives the same value, on any machine and in any language, which is what makes v5 the tool for identifiers that have to be derived rather than issued.

RFC 9562 § 6.5 · Name-Based UUID GenerationWhat the derivation does with the namespace and the name

The three that are jokes with a point#

deadbeef, cafebabe and palindrome are in the list because a recognisable identifier is genuinely useful in a fixture: nobody mistakes deadbeef-dead-beef-dead-beefdeadbeef for production data, and a palindrome makes a byte-order bug visible at a glance, since reversing it changes nothing.

Which to pick#

  • A database key: v7.
  • An identifier and nothing else: v4.
  • The same input must always give the same identifier: v5.
  • You are matching an older system: v1, v6 or v3, whichever it already writes.
  • A placeholder or a range bound: Nil and Max.

Questions people actually ask#

Can I generate a UUID for a specific date?

Yes, for the versions that carry a clock: v1, v6, v7 and ULID. Set the moment and the timestamp field is filled from it.

Which version does the generator make by default?

v4, the random one, which is what most systems expect when nothing else is specified.

Are the generated identifiers sent anywhere?

No. They are made in this page by the same code the converter runs, and nothing leaves the tab.

Browse the reference