UUID Generator
Generate UUID v4 (random) and UUID v7 (time-ordered) identifiers in bulk. Supports standard, uppercase, no-hyphens, and braces formats with one-click copy.
The UUID Generator is a free, browser-based tool that creates universally unique identifiers instantly. Choose between UUID v4 (random) and UUID v7 (time-ordered), set the quantity and format, and get as many UUIDs as you need with a single click. All generation uses your browser's built-in cryptographic random number generator — no data is sent to any server.
Features
| Feature | Detail |
|---|---|
| UUID v4 (random) | Fully random 128-bit identifier using crypto.randomUUID() |
| UUID v7 (time-ordered) | 48-bit Unix timestamp prefix + random bits — sortable by creation time |
| Bulk generation | Generate 1, 5, 10, 25, 50, or 100 UUIDs in one click |
| Format options | Standard lowercase, uppercase, no hyphens, or with braces { } |
| Per-row copy | Copy any individual UUID to the clipboard with one click |
| Copy all | Copy the entire batch as a newline-separated list |
| Auto-generate on load | One UUID is generated immediately when you open the tool |
How to Use
- Select a UUID version — v4 for fully random identifiers, v7 for time-sortable identifiers.
- Choose how many UUIDs to generate from the Count dropdown.
- Select an output Format (lowercase, uppercase, no hyphens, or braces).
- Click Generate.
- Click the copy icon next to any UUID to copy it individually, or click Copy all to copy the full batch.
UUID Versions
UUID v4 — Random
UUID v4 generates a 128-bit value where 122 bits are filled with cryptographically random data. The remaining 6 bits encode the version (4) and the RFC 4122 variant (10). Because the probability of a collision is astronomically low — roughly 1 in 5.3 × 10³⁶ — v4 UUIDs are considered globally unique for all practical purposes.
Structure: xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx
Where x is random and y is one of 8, 9, a, or b (variant bits).
Use when: You need a unique identifier and sortability by creation time is not required.
UUID v7 — Time-ordered
UUID v7 (defined in RFC 9562, published 2024) encodes a 48-bit Unix timestamp in milliseconds in the most significant bits. The remaining bits are filled with random data. Because the timestamp prefix increases monotonically, v7 UUIDs sort lexicographically in the order they were created.
Structure: tttttttt-tttt-7xxx-yxxx-xxxxxxxxxxxx
Where t encodes the timestamp, 7 is the version, and x/y are random bits with the variant marker.
Use when: You are using UUIDs as database primary keys and want natural chronological ordering without a separate created_at column index.
Format Options
| Format | Example |
|---|---|
| Standard (lowercase) | 550e8400-e29b-41d4-a716-446655440000 |
| Uppercase | 550E8400-E29B-41D4-A716-446655440000 |
| No hyphens | 550e8400e29b41d4a716446655440000 |
| With braces | {550e8400-e29b-41d4-a716-446655440000} |
The braces format is commonly used in Microsoft environments (COM/GUID notation). The no-hyphens format is sometimes required for database column types that store UUIDs as a 32-character hex string.
Why UUIDs?
UUIDs allow systems to generate unique identifiers independently — without a central authority or a database auto-increment sequence. This makes them ideal for:
- Distributed systems where multiple nodes create records simultaneously
- Client-side ID generation before a record is persisted to a database
- Public-facing identifiers that do not expose sequential information (unlike integer IDs)
- Merge and replication scenarios where records from multiple databases must be combined without ID conflicts
- Event sourcing and CQRS architectures where events need stable identifiers across services
Frequently Asked Questions
Are the generated UUIDs truly unique?
UUID v4 uses cryptographic randomness (crypto.getRandomValues). The probability of generating two identical UUIDs is approximately 1 in 5.3 × 10³⁶, making collisions impossible in practice for any realistic workload.
What is the difference between a UUID and a GUID?
GUID (Globally Unique Identifier) is Microsoft's name for what the RFC defines as a UUID. They are the same 128-bit format. GUIDs are often displayed with surrounding braces, which is one of the format options this tool provides.
When should I use v7 instead of v4?
Use v7 when your UUIDs will be used as database primary keys and you want rows to be physically stored in insertion order (important for B-tree indexes in PostgreSQL, MySQL, and SQLite). Random v4 UUIDs cause index fragmentation over time. v7's timestamp prefix keeps new rows adjacent on the index, improving insert performance at scale.
Can I use UUIDs as database primary keys?
Yes. Most relational databases support UUID primary keys natively. PostgreSQL has a UUID type. MySQL and MariaDB support CHAR(36) or BINARY(16) for UUIDs. Using BINARY(16) with the hyphens stripped (no-hyphens format) is the most storage-efficient option.
Why does UUID v4 have a 4 in the third group?
The third group's first character indicates the version. A 4 means v4 (random). A 7 means v7 (time-ordered). The first character of the fourth group (8, 9, a, or b) indicates the RFC 4122 variant (binary 10xx).
Is it safe to expose UUIDs publicly in URLs?
Yes. UUIDs do not leak sequential information the way integer IDs do — an attacker cannot enumerate records by incrementing an ID. v4 UUIDs are purely random, making them safe for public URLs, API endpoints, and token references.
What does "time-ordered" mean for v7?
Time-ordered means that a UUID generated at a later point in time will sort lexicographically after one generated earlier. This is because the 48-bit Unix timestamp (in milliseconds) occupies the most significant bits. Within the same millisecond, ordering is random.