Skip to content
UUID App
Contact
UUID App

UUID v8 Generator

Your example UUID v8 is ready below. Click Copy to use it, or Generate for a fresh one.

Your UUID v836 characters
xxxxxxxx-xxxx-8xxx-8xxx-xxxxxxxxxxxx
  • Free, no sign-up
  • Follows the official RFC 9562 standard

Free UUID generator: v4, v7, GUID and more

Need more? Make them in bulk

Make up to 10,000 UUID v8s at once and save them as a file. Three quick steps.

Pick a file type
Check and download

What is a UUID v8?

A UUID v8 is a UUID with a layout you design yourself. Only the version and variant digits are fixed. The other 122 bits mean whatever you decide.

RFC 9562 added version 8 for vendor-specific and experimental formats, such as an ID that packs in a shard number, your own time format or a hash. The standard only promises that the ID is 128 bits with the right version and variant. Whether it is unique depends on your design.

There is no single way to make a v8, so this page shows an example. It fills the 122 free bits with secure random data and sets the version and variant. The result is a valid v8, but it is only a demonstration. If you just want random IDs, use UUID v4, which every library and database already understands.

What a UUID v8 looks like

Here is the ID you just made, split into its parts. Click Generate above and watch it change.

  • The 8 means version 8. It is always in this spot.
  • This digit is always 8, 9, a or b. It marks the standard layout.
  • Everything else is yours to define: 122 bits. Here they are random, as an example.
Need 10,000 UUIDs? Export to CSV, JSON or SQL. Try it free

When to use UUID v8

Good for

  • Packing your own data, like a shard or region number, into a standard UUID
  • Name-based IDs that use a newer hash, such as SHA-256
  • Prototypes and experiments with new ID schemes
  • Test data for code that must accept any UUID version

Pick something else when

  • You just need a random ID: UUID v4
  • You need IDs that sort by time: UUID v7
  • The same name must always give the same ID: UUID v5

Make a UUID v8 in code

const b = crypto.getRandomValues(new Uint8Array(16));
b[6] = (b[6] & 0x0f) | 0x80; // version 8
b[8] = (b[8] & 0x3f) | 0x80; // variant
const hex = [...b].map((x) => x.toString(16).padStart(2, '0')).join('');
const id = [hex.slice(0, 8), hex.slice(8, 12), hex.slice(12, 16), hex.slice(16, 20), hex.slice(20)].join('-');
console.log(id);

Built into browsers and Node.js. The uuid package has no v8 function, since the layout is yours. Put your own bits in b.

UUID v8 vs other versions

VersionMade fromSorts by timeReveals
v8 (this page)Your own layoutIf you design it toWhatever you put in
v4Random bitsNoNothing
v7Time + randomYesCreation time
v5Hash of a nameNoNothing
Need 10,000 UUIDs? Export to CSV, JSON or SQL. Try it free

Questions people ask

What is UUID v8 for?

Custom formats. If you need to pack your own data into a 128-bit UUID, v8 lets you do it while still marking the ID as a valid UUID.

Is a random UUID v8 the same as a v4?

Almost. Both have 122 random bits here. But a v8 tells readers the layout is custom, so tools assume nothing about it. For random IDs, use UUID v4.

Are UUID v8s unique?

Only if your layout makes them unique. The standard leaves that to you. Random bits, like the ones on this page, make a repeat very unlikely.

Which parts of a UUID v8 must I keep?

The version digit, which is always 8, and the variant bits, which make the first digit of the fourth group 8, 9, a or b. You define the other 122 bits.

Can a decoder read my UUID v8?

It can tell it is a v8, but not what your bits mean, since only you know the layout. The UUID decoder shows the version and variant.