UUID v4 Generator

Generate RFC 9562 version 4 UUIDs from 122 random bits, with an optional seed for reproducible results.

Description

Generate RFC 9562 UUID version 4 identifiers with the required random, version, and variant bit layout.

A UUID is a 128-bit identifier designed to be generated without a central numbering authority. Version 4 reserves six structural bits and fills the other 122 bits with random or pseudorandom data. This tool can generate up to 100 lowercase canonical UUIDs and accepts an optional seed for reproducible testing.1

When to use UUID v4 Generator

Use UUID v4 when identifiers should not reveal time or hardware information and random uniqueness is appropriate. Omit the seed for ordinary generation; provide a seed only when stable fixtures or demonstrations are more important than unpredictability.

How UUID v4 Generator works

The generator produces 16 bytes, replaces the high nibble of byte 6 with version 4, and replaces the high two bits of byte 8 with the RFC variant bits 10. It then formats the bytes as 8-4-4-4-12 hexadecimal groups.1

How the UUID version 4 generation function processes input

  1. Generate 128 pseudorandom bits.
  2. Set bits 48–51 to 0100 for version 4.
  3. Set bits 64–65 to 10 for the RFC 9562 variant.
  4. Format the 16 bytes as a lowercase hyphenated UUID.

Limitations and assumptions

  • A repeated seed produces repeated UUIDs and must not be treated as unpredictable.
  • Uniqueness is probabilistic and depends on a sound random source and correct generation.
  • UUIDs are identifiers, not secrets, access tokens, signatures, or proof of authenticity.

Alternative or Complementary approaches

Use UUID v7 when roughly time-sortable identifiers benefit database locality. Use the parser and validator to inspect identifiers received from elsewhere.

References

  1. RFC 9562: Universally Unique IDentifiers (UUIDs) — RFC Editor

Similar or alternative tools

Don't forget to set a bookmark for tool.io!
Privacy | Imprint | Cookies