UUID vs GUID

Est. read: 6 minDeveloper
UUID blocks representing unique identifiers

Summary

Definition: UUID is a standardized 128-bit identifier; GUID is Microsoft's compatible name for it.

Why it matters: Correct UUID choices improve interoperability, performance, and data safety.

Pitfall: UUIDs provide uniqueness, not security.

Guide start

UUID is the standardized identifier defined by the IETF. GUID is Microsoft's name for the same
128-bit identifier format, and the two are fully interoperable.

Key terms
UUID
Standardized 128-bit identifier defined by the IETF.
GUID
Microsoft term for a UUID-compatible identifier.
Version
Indicates the UUID generation method.
Variant
Defines the UUID layout and compatibility.

UUID format

The canonical UUID string has 32 hexadecimal characters displayed as 8-4-4-4-12 with hyphens.

Many systems accept non-hyphenated forms, but the hyphenated form is the canonical representation.

UUID vs GUID
UUID
IETF standardized identifier.
GUID
Microsoft terminology.
Both
Same 128-bit format.

Common mix-up: UUIDs and GUIDs are different standards. They use the same format and values.

UUID versions

Version Best for
v1 Legacy systems using time and node data
v4 Random, general-purpose identifiers
v5 Stable, name-based identifiers
v7 Time-ordered identifiers for databases

Most modern systems use the RFC 4122 variant defined by the IETF.

Quick example

Example

A randomly generated UUID using the canonical 8-4-4-4-12 format.

UUID v4
f47ac10b-58cc-4372-a567-0e02b2c3d479

Try it yourself

  • Generate a UUID using the standard tool.
  • Use UUID v7 when ordering or indexing matters.

Practical check

Practical check
  • Generate a UUID.
  • Confirm the 8-4-4-4-12 pattern.
  • Store UUIDs consistently in lowercase.

FAQ

Are GUID and UUID the same? Yes. GUID is Microsoft's name for a UUID-compatible identifier.

Which UUID version should I use? Use v4 for random IDs, v7 for ordered IDs, and v5 for deterministic name-based IDs.

Are UUIDs secure? No. UUIDs are identifiers, not secrets.

Guide end - You can now select, generate, and use UUIDs and GUIDs correctly.Back to top