Security & Database

UUID Generator (v4, v7 RFC 9562), ULID & NanoID — 100% Private Web Crypto

Generate cryptographically secure UUID v4, time-ordered UUID v7 (RFC 9562), sortable ULID, and NanoID in bulk using native browser Web Crypto API. 100% client-side privacy.

What is the Difference Between UUID v4 and UUID v7?

UUID v4 creates random IDs. These random IDs slow down database index writes. UUID v7 solves this issue. It adds a millisecond timestamp prefix. Databases can now store records in chronological order.

100% In-Browser Generation • High-Entropy Web Crypto API • Zero Server Telemetry
WhatsApp
10

Generated Identifiers

10 Items

Guide: UUID v4, UUID v7, and ULID Keys

Unique keys identify database records. UUID v4 uses pure random values. It works well for simple tokens and session IDs.

UUID v7 works better for databases. It places a timestamp at the start. Database engines like PostgreSQL insert rows in order. This prevents index fragmentation and cuts disk write costs.

ULID provides 26-character sortable IDs. It avoids confusing letters like I, L, and O. NanoID creates compact 21-character random IDs.

All IDs are generated locally in your browser. The tool uses the native Web Crypto API. Your data never leaves your device.

UUID v4 vs. UUID v7 vs. ULID vs. NanoID Technical Comparison

Evaluation matrix for distributed primary keys, database B-Tree index fragmentation, and sorting semantics (RFC 9562 & RFC 4122).

IdentifierStandardTime-OrderedDatabase Index EfficiencyEntropy / CollisionsIdeal Use Case
UUID v7 RecommendedRFC 9562 (2024)✅ Millisecond Epoch⚡ Optimal (Sequential)High (74 bits random)Postgres/MySQL DB Primary Keys
UUID v4 StandardRFC 4122❌ Pure Random⚠️ Fragmented (Random splits)Max (122 bits random)Ephemeral tokens, non-indexed IDs
ULID AlternativeULID Spec✅ Millisecond Epoch⚡ Optimal (Lexicographical)High (80 bits random)Distributed event streams / Kafka
NanoID CompactNanoID Spec❌ Pure Random⚠️ FragmentedConfigurableURL shorteners & web slugs
Frequently Asked Questions (FAQ) · UUID & GUID Generator — Bulk UUID v4 & UUID v7 (RFC 9562)

UUID Generator — RFC 9562 v4, v7 & Nil UUID Technical Guide

Generate RFC 9562 compliant UUID v4 (random), v7 (time-ordered), and Nil UUIDs client-side using crypto.getRandomValues() for cryptographically secure entropy.

MU
IBM Maximo & Developer Tools Architect
Technical Reference

01. UUID Standards: RFC 9562 Version 4 & 7 Structure

A Universally Unique Identifier (UUID) is a 128-bit label standardized in RFC 9562. The canonical text format uses 32 hexadecimal digits grouped as 8-4-4-4-12 separated by hyphens. The M nibble encodes the version (4 or 7) and the N nibble encodes the variant (10xx for RFC 9562 compliant UUIDs).

UUID v4 uses 122 bits of cryptographically random data. With crypto.getRandomValues() providing 122 bits of entropy, the probability of UUID collision in 1 billion generated IDs is approximately 1 in 5.3 x 10^20 — statistically negligible for any practical system.

UUID v7 (new in RFC 9562) embeds a 48-bit Unix millisecond timestamp in the most significant bits, followed by 74 bits of random data. Unlike v4, v7 UUIDs are lexicographically sortable by creation time, making them significantly more efficient as primary keys in B-tree database indexes.

  • UUID v4 (RFC 9562 §5.4): 122 random bits — global uniqueness without coordination.
  • UUID v7 (RFC 9562 §5.7): 48-bit ms timestamp + 74 random bits — sortable database PKs.
  • Nil UUID (RFC 9562 §5.9): 00000000-0000-0000-0000-000000000000 — sentinel placeholder.
  • COMB UUIDs: timestamp-prefixed v4 hybrid — widely used in ORMs for index performance.
Database Performance: UUID v7 vs v4

UUID v4 random primary keys cause 50-80% B-tree page fragmentation in PostgreSQL and MySQL at scale. UUID v7 monotonically increasing prefix eliminates fragmentation, achieving near-sequential INSERT performance comparable to auto-increment integers.

02. Entropy Sources & Uniqueness Guarantees

Browser UUID generation uses crypto.getRandomValues(), which reads from the operating system CSPRNG: /dev/urandom on Linux, CryptGenRandom on Windows, and SecRandomCopyBytes on macOS/iOS. These CSPRNGs are seeded from hardware entropy sources including CPU timing jitter and thermal sensor noise.

Math.random() must never be used for UUID generation: it is a deterministic PRNG with only 32-64 bits of internal state, making it trivially predictable and unsuitable for unique identifier generation in security-sensitive contexts.

  • crypto.getRandomValues(): CSPRNG-backed — cryptographically unpredictable per W3C spec.
  • Math.random(): Deterministic PRNG — NOT suitable for UUID generation.
  • UUID v7 timestamp: millisecond precision per RFC 9562 — sortable without clock sync.

Frequently Asked Questions (FAQ)

Should I use UUID v4 or v7 for database primary keys?

UUID v7 is recommended for new database schemas. Its monotonically increasing timestamp prefix eliminates B-tree fragmentation and delivers better INSERT performance at scale.

Are UUIDs generated here truly random?

Yes. This tool uses crypto.getRandomValues() from your OS CSPRNG. The 122 random bits in v4 make collisions statistically impossible in practice.

What is the Nil UUID used for?

The Nil UUID (all zeros) is a sentinel value defined in RFC 9562 §5.9, used as a placeholder when a UUID field is required but no actual ID has been assigned yet.

Is my confidential data uploaded to external servers when using UUID & GUID Generator — Bulk UUID v4 & UUID v7 (RFC 9562)?

No. Core processing in UUID & GUID Generator — Bulk UUID v4 & UUID v7 (RFC 9562) executes in volatile browser memory without server uploads. Inputs to local tools are not logged on remote servers; optional cloud-assisted features require user consent.

Can I use UUID & GUID Generator — Bulk UUID v4 & UUID v7 (RFC 9562) offline without an active internet connection?

Offline use requires the page and its tool assets to finish caching first. Core transformations can then run locally; optional AI and contact delivery require internet.

Is UUID & GUID Generator — Bulk UUID v4 & UUID v7 (RFC 9562) free to use with any rate limits or paywalls?

Core tools are free to use without an account. Device memory and tool-specific safety limits apply. Optional AI and online contact services have usage limits.

More free tools that run safely in your web browser.

Explore the tool directory