UUID v4 / v7 Generator
Generate cryptographically secure UUID v4, time-sorted UUID v7, UUID v1, and deterministic UUID v5 in single or bulk batches.
Generate RFC 9562 UUIDs across v4 Random, v7 Timestamp-Ordered, v1, v3, v5, and NIL with bulk export.
Select UUID Version
UUID Formatting & Batch Options
How do I use UUID v4 / v7 Generator?
Select your UUID version (`v4` Random, `v7` Time-Ordered, `v1`, `v3`, `v5`, or `NIL`) or click 'Load Sample Data'.
Set the bulk generation count (1–1,000) and formatting toggles (Uppercase, Hyphens, or `{Braces}`).
Copy individual UUIDs or download the batch as a `.txt` or `.json` file.
What features does UUID v4 / v7 Generator offer?
Cryptographically secure UUID v4 generation via Web Crypto API
Bulk generation (1 to 100 UUIDs)
Custom formatting (uppercase, hyphens, braces)
1-click copy or export as TXT/JSON
RFC 9562 (Formerly RFC 4122) UUID Version Bit Layouts & Database Indexing
RFC 9562 standardizes 128-bit Universally Unique Identifiers (`8-4-4-4-12` hex digits), introducing timestamp-ordered UUID v7 specifically for high-throughput B-tree database primary keys.
| UUID Version | Entropy / Source | Sortable by Time? | B-Tree Index Performance & Primary Use Case |
|---|---|---|---|
| UUID v4 | 122 bits CSPRNG random | No (Completely random) | Causes B-tree page splits at scale; great for stateless tokens |
| UUID v7 (RFC 9562) | 48-bit Unix ms + 74-bit random | Yes (Monotonic) | Sequential B-tree appends; best for PostgreSQL/MySQL PKs |
| UUID v5 / v3 | SHA-1 (v5) / MD5 (v3) of Namespace+Name | No (Deterministic) | Idempotent deterministic IDs from URLs or DNS names |
| NIL UUID | All 128 bits set to 0 | N/A | Sentinel / empty placeholder (00000000-0000-0000-0000-000000000000) |
Frequently Asked Questions about UUID v4 / v7 Generator
Why should I use UUID v7 instead of UUID v4 for PostgreSQL or MySQL primary keys?
UUID v4 is completely random, forcing database B-tree indexes to insert new rows into random disk pages and causing severe index fragmentation and buffer-pool thrashing on large tables. UUID v7 (RFC 9562) prefixes a 48-bit Unix millisecond timestamp so new rows append sequentially like `AUTO_INCREMENT` while remaining globally unique.
What is the probability of a collision when generating UUID v4?
UUID v4 has 122 random bits ($2^{122} \approx 5.3 \times 10^{36}$ possible values). By the birthday paradox, you would need to generate roughly 2.71 quintillion ($2.71 \times 10^{18}$) UUIDs to reach a 50% chance of a single collision.
What is the difference between UUID v3 and UUID v5?
Both generate deterministic, reproducible UUIDs by hashing a Namespace UUID with an input name string: passing the exact same name always yields the exact same UUID. UUID v3 uses MD5, whereas UUID v5 uses SHA-1 (RFC 9562 recommends v5 over v3).
Does removing hyphens save storage space in PostgreSQL `uuid` columns?
In PostgreSQL's native 16-byte `uuid` data type, hyphens are stripped during binary storage anyway. Removing hyphens only saves 4 bytes per ID when storing UUIDs as `VARCHAR(32)` or transmitting them in JSON payloads.
Explore Related Developer Tools
Password Generator
Generate strong random passwords with custom length, character sets, and bit entropy meter.
GitHub Webhook Signature Tester
Compute and verify GitHub X-Hub-Signature-256 (sha256=<hex>) HMAC-SHA256 webhook headers for push and pull_request events.
Bcrypt & Argon2 Password Hash Generator & Verifier
Generate cryptographically secure Bcrypt password hashes ($2b$) with custom cost rounds, or test password verification.
Hash Generator
Generate MD5, SHA-1, SHA-256, and SHA-512 cryptographic hash digests from text or files.
JWT Decoder
Decode and inspect JSON Web Tokens. View header, payload, signature, and expiration status.
HMAC Signature Generator
Generate and verify HMAC signatures (HMAC-SHA256, HMAC-SHA512) for Stripe, GitHub, Shopify, and Webhook verification.