What Is a UUID?
A UUID (Universally Unique Identifier), also known as a GUID (Globally Unique Identifier), is a 128-bit number used to uniquely identify records, objects, transactions, and resources across distributed systems without requiring centralized coordination. The format is defined by RFC 4122 and consists of 32 hexadecimal digits displayed in five groups separated by hyphens: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx.
UUID v4 — the most commonly used version — generates all 122 random bits using a cryptographically secure random number generator. This produces approximately 5.3 × 10³⁶ unique possible values, making collision probability negligible even in extremely large-scale distributed systems.
UUID vs GUID — Are They the Same?
UUID (Universally Unique Identifier)
- Industry-standard term defined by RFC 4122 and ISO/IEC 9834-8
- Used in Linux, macOS, web standards, IETF protocols
- Standard across databases: PostgreSQL, MySQL, SQLite
- Used in AWS resource ARNs, GCP, Kubernetes
GUID (Globally Unique Identifier)
- Microsoft's terminology for the same 128-bit identifier
- Used in Windows, .NET, COM/ActiveX, Azure services
- Identical format and structure to UUID
- SQL Server uses UNIQUEIDENTIFIER data type for GUIDs
Bottom line: UUID and GUID are functionally identical. A UUID generated by this tool is valid wherever a GUID is expected, and vice versa. The only difference is the terminology used in different ecosystems.
UUID v4 Anatomy
550e8400-e29b-41d4-a716-446655440000
Random bits
122 bits of cryptographically random data
Version (4)
Third segment always starts with '4' — identifies UUID v4
Variant (8, 9, a, b)
Fourth segment starts with 8/9/a/b — RFC 4122 variant bit
Common UUID Use Cases
Database Primary Keys
Distributed unique IDs for PostgreSQL, MySQL, MongoDB rows.
REST API Request IDs
Trace and correlate HTTP requests across microservices.
Microservice Correlation IDs
Link logs, spans, and events across distributed systems.
Session Identifiers
Secure, unpredictable session tokens for web applications.
File Tracking Systems
Unique identifiers for uploads, assets, and documents.
Distributed Event Processing
Idempotency keys for queues and event sourcing systems.
Cloud Resource IDs
Resource naming in AWS, GCP, Azure, and Kubernetes.
IoT Device Registration
Globally unique device identifiers for IoT fleets.