What is a UUID Generator?
Need a fresh primary key without coordinating with a central sequence? UUIDs give you 128 bits of identifier space that's effectively collision-free across any number of nodes, generated locally.
A UUID is 32 hexadecimal digits displayed in five hyphen-separated groups following RFC 4122. The version digit (4th group, first character) tells you how it was built: random, time-based, or hashed from a namespace.
This generator covers v1 (time-based), v3 (MD5 namespace hash), v4 (random), v5 (SHA-1 namespace hash), and the NIL UUID. Generate one at a time or in batches of 100, choose case, and optionally strip the hyphens.
How to Use Our UUID Generator
- Select the UUID version you want to generate
- Set the number of UUIDs to generate (except for NIL UUID)
- For hash-based UUIDs (v3 and v5), specify the namespace and name
- Choose formatting options (uppercase or lowercase, with or without hyphens)
- Click "Regenerate" to create new UUIDs any time
- Copy individual UUIDs or all at once to your clipboard
- Download all generated UUIDs as a text file
Examples
UUID v4 pulls 122 bits from crypto.getRandomValues, sets the version and variant bits, then formats the result as 8-4-4-4-12 hex groups. Formatting options rewrite the presentation without changing the underlying value.
Example 1: Batch of random v4 UUIDs
Set the count to 3 and the version to v4 — each row is a fresh 128-bit random identifier with no relation to the others.
Input
Version: v4
Count: 3
Case: lowercase
Hyphens: on
Output
f47ac10b-58cc-4372-a567-0e02b2c3d479
7c9e6679-7425-40de-944b-e07fc1f90ae7
9b2a8c1d-3e4f-4a5b-8c6d-7e8f9a0b1c2d
Example 2: Same UUID in different formats
The same 128-bit value rendered as the standard form, a compact 32-char hex string, uppercase, and the Microsoft GUID style with braces.
Input
Base UUID: f47ac10b-58cc-4372-a567-0e02b2c3d479
Output
Standard: f47ac10b-58cc-4372-a567-0e02b2c3d479
No hyphens: f47ac10b58cc4372a5670e02b2c3d479
Uppercase: F47AC10B-58CC-4372-A567-0E02B2C3D479
GUID braces: {f47ac10b-58cc-4372-a567-0e02b2c3d479}Supported UUID Versions
Version 1 - Time-based
Generated using the current timestamp and MAC address. Useful when you need to track when an ID was created. Format: xxxxxxxx-xxxx-1xxx-yxxx-xxxxxxxxxxxx
Version 3 - MD5 Hash-based
Generated by applying MD5 hash to a namespace and name. Produces the same UUID for the same inputs. Format: xxxxxxxx-xxxx-3xxx-yxxx-xxxxxxxxxxxx
Version 4 - Random
Generated using random or pseudo-random numbers. The most commonly used version for general purposes. Format: xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx
Version 5 - SHA-1 Hash-based
Similar to v3, but uses SHA-1 hash instead of MD5. More secure and recommended over v3. Format: xxxxxxxx-xxxx-5xxx-yxxx-xxxxxxxxxxxx
NIL UUID
Special UUID with all bits set to zero: 00000000-0000-0000-0000-000000000000. Used for special cases or as a default value.
Key Features
All RFC 4122 versions are supported, with batch generation up to 100 at a time, case formatting, and the option to strip hyphens. For v3 and v5, you can set the namespace and name inputs that feed the hash. Results copy to the clipboard individually or as a bulk list, and you can download the whole batch as a text file.
Typical Use Cases
- Database primary keys (v4 is the usual default)
- Distributed system identifiers with no central coordinator
- Time-ordered sequences (v1)
- Content-derived deterministic IDs (v3 / v5)
- Session tokens
Why Use Our UUID Generator?
The generator covers common workflows without getting in the way:
- Complete version support: Generate any type of UUID for your specific requirements
- Privacy-focused:All UUIDs are generated directly in your browser - we don't store any data
- Versatile options: Multiple format options, batch generation, and advanced settings
- Educational: Learn about different UUID versions and their applications
- Instant access: No need to install any software or register
- Export flexibility: Copy to clipboard or download as a text file
UUID Version Format
All UUIDs follow the format: xxxxxxxx-xxxx-Mxxx-Nxxx-xxxxxxxxxxxx where:
- x is any hexadecimal digit (0-9, a-f)
- M is the version number (1, 3, 4, 5 or 0 for NIL)
- N is a variant digit (8, 9, a, or b for RFC 4122 UUIDs)
The probability of generating two identical UUIDs is extremely low, especially for version 4, making them suitable for most distributed computing applications where uniqueness is essential.
Frequently Asked Questions
Q: What is the difference between UUID v1 and v4?
UUID v1 is generated using the current timestamp and MAC address, making it sortable by creation time but potentially revealing device information. UUID v4 is entirely random, providing better privacy and unpredictability at the cost of not being time-sortable.
Q: Are the generated UUIDs truly random?
Yes, UUID v4 values are generated using the Web Crypto API (crypto.getRandomValues), which provides cryptographically secure random numbers. This ensures the generated UUIDs are unpredictable and suitable for security-sensitive applications.
Q: What is the probability of UUID collision?
The probability is astronomically low. UUID v4 has 122 random bits, meaning you would need to generate approximately 2.71 quintillion UUIDs to have a 50% chance of a single collision. For all practical purposes, collisions will never occur.
Q: Can I use these UUIDs as database primary keys?
Yes, UUIDs are commonly used as primary keys in distributed databases. They allow independent ID generation across multiple nodes without coordination. Consider UUID v7 if you need time-sortable keys for better index performance.
Q: What is the difference between UUID v4 and v7?
UUID v4 is purely random, using 122 bits of randomness with no inherent ordering. UUID v7 (defined in RFC 9562) embeds a Unix timestamp in the first 48 bits, making it time-sortable while still including randomness. v7 is ideal for database primary keys where index performance matters, as sequential IDs reduce B-tree fragmentation compared to fully random v4 UUIDs.