UUID vs GUID: Generate Version 4 IDs Online (When to Use Which)
Table of contents
UUID and GUID are the same idea with different accents. UUID is the RFC 4122 name. GUID is Microsoft's name for the same 128-bit value, usually printed with extra braces or uppercase hex. A version 4 UUID is 122 random bits plus a 4-bit version nibble. You use it when you need an ID that does not require a database round-trip to stay unique across machines.
UUID Generator creates v4 values in your browser with the same cryptographic randomness the platform gives to crypto.getRandomValues. Nothing is sent to a server. That matters if you are pasting IDs into configs that also contain secrets.
When v4 is the right choice
- Primary keys you mint in the client or in multiple services that cannot share a sequence.
- Idempotency keys for API writes.
- Filenames and object-store keys where two writers must not collide.
- Correlation IDs in logs.
v4 is random. It does not sort by time. If you need IDs that roughly increase as they are created (for B-tree locality), look at ULID or UUID v7, not this generator.
What people mix up
- UUID vs GUID: same identifier. Formatting differs:
3f63...vs{3F63...}. Parse both as 128-bit values. - v1 vs v4: v1 embeds a timestamp and, historically, a MAC address. v4 is random. Prefer v4 unless you have a reason for time-based IDs.
- Collision: practically zero for v4 from a real CSPRNG. Do not use
Math.random()to roll your own. - Security: a v4 UUID is an identifier, not a session secret. Do not treat guessability the same as a 256-bit API key. For secrets, use a password / key generator.
How to generate one
- Open UUID Generator.
- Generate one or many v4 values.
- Copy the format your stack wants: lowercase hyphenated is the usual JSON/API form.
Frequently asked questions
Is a GUID the same as a UUID?
Yes, for practical purposes. It is a 128-bit identifier. Names and string formats differ.
Can two UUID v4 values collide?
In real systems, you will hit operational bugs long before a CSPRNG v4 collision. Do not use a weak random source.
Should I use UUIDs as passwords?
No. Generate a dedicated secret. A UUID is unique, not high-entropy in the password-manager sense you want for credentials.
Open the UUID Generator and copy a v4 ID. Free, private, no signup.