Home / UUID Generator

UUID Generator (v4)

A UUID (Universally Unique Identifier) is a 128-bit identifier that is unique across all space and time. This tool generates random UUID version 4 identifiers that can be used for database keys, distributed systems, and more.

01b4bc0865-94f1-4023-a0be-05d07b0da303

Version

4 (Random)

Randomly generated

Format

RFC 4122

8-4-4-4-12 pattern

Uniqueness

122 bits

~5.3 x 10^36 combinations

How to Generate UUIDs

  1. 1

    Select Count

    Choose how many UUIDs you want to generate (1, 5, 10, 25, or 50 at a time).

  2. 2

    Choose Format

    Select your preferred format: lowercase, UPPERCASE, or without hyphens.

  3. 3

    Generate & Copy

    Click "Generate" to create new UUIDs, then copy individual UUIDs or all at once.

Frequently Asked Questions

What is a UUID?

UUID (Universally Unique Identifier) is a 128-bit identifier that is unique across space and time. UUIDs are used to identify information in computer systems without requiring a central authority to coordinate ID generation.

What is UUID version 4?

UUID v4 is a randomly generated UUID. It uses random or pseudo-random numbers to generate the identifier, making it simple to implement and suitable for most use cases. The probability of generating duplicate UUIDs is extremely low.

How unique are UUIDs?

UUIDs have 122 random bits, resulting in approximately 5.3 x 10^36 possible combinations. The probability of generating two identical UUIDs is so low that it's considered practically impossible for most applications.

When should I use UUIDs?

UUIDs are ideal for database primary keys, distributed systems where multiple nodes need to generate IDs independently, file naming, session tokens, and any scenario where you need unique identifiers without a central coordinator.

Use Cases

Database primary keys: UUIDs let multiple services or distributed nodes generate IDs without coordination. No single point of failure, no locking.

File and object storage: Use UUIDs as unique filenames or object keys to avoid collisions when uploading from many clients.

API request IDs: Correlate requests across logs by attaching a UUID to each request. Helps trace distributed flows.

Session and token IDs: Non-guessable IDs for sessions. Note: for secrets, use cryptographically random tokens, not raw UUIDs.

CLI and Code

# Node.js (v19+)
crypto.randomUUID()
# Python
import uuid; uuid.uuid4()
# PostgreSQL
gen_random_uuid()

UUID Versions

We generate UUID v4 (random). v1 includes timestamp and MAC; v7 is time-ordered and better for database indexing. For most apps, v4 is sufficient. If you need sortable IDs, consider ULID or UUID v7.

Security Notes

UUIDs are not secrets. They are meant to be unique, not unguessable. For tokens, session IDs, or API keys, use at least 128 bits of cryptographically secure random data (e.g. crypto.randomBytes(32)) and encode as hex or Base64. UUID v4 is fine for IDs that will be exposed (e.g. in URLs) but should not be used as the sole secret.