// free ยท runs in your browser ยท nothing uploaded
UUID v4 vs v7 vs GUID: Which One to Use
How random UUID v4 and time-ordered UUID v7 differ, what a GUID is, and when generating them in bulk makes sense.
๐ Official sources: UUID standard (RFC 9562)
We build every tool from the official rules and re-check them when they change. Always confirm with the official source before you rely on a result.
๐ ๏ธ Spotted a mistake or an out-of-date rule? Tell us
Side by side
| Type | What's inside | Sortable by time | Use it for |
|---|---|---|---|
| UUID v4 | 122 random bits | No | General IDs, tokens that must not reveal time |
| UUID v7 | 48-bit Unix time in ms + 74 random bits | Yes | Database primary keys (fewer index page splits) |
| GUID | Microsoft's name for a UUID (usually v4) | No | .NET, SQL Server, Windows |
| Bulk | Up to 1,000 at once, v4 or v7 | โ | Seeding test data, fixtures |
Both versions are 128 bits written as 36 characters (8-4-4-4-12). v7 is defined in RFC 9562 (2024); because it starts with the timestamp, new rows land at the end of a B-tree index. All IDs here come from the browser's cryptographic random generator.
Related tools
Questions people ask
What is the difference between UUID v4 and v7?+
v4 is fully random. v7 starts with the time it was created (in milliseconds) followed by random bits, so v7 IDs sort by creation time. That makes them faster as database primary keys.
Can two UUIDs ever be the same?+
In practice, no. A v4 UUID has 122 random bits: you would need to make billions every second for many years to have a real chance of a duplicate.
Is a GUID the same as a UUID?+
Yes. GUID is Microsoft's name for the same 128-bit identifier. Tick UPPERCASE and braces to get the {XXXXXXXX-โฆ} style used in Windows and .NET.