ID generators

UUID Generator (v4 and v7)

Create random (v4) or time-ordered (v7) UUIDs one at a time or a thousand at once, then inspect any UUID to see its version, variant and creation time.

  • Free foreverNo trial, no paywall, no usage limits.
  • No sign-upOpen the page and start. We never ask for an email to use a tool.
  • PrivateEverything runs in your browser. Your input is never uploaded or stored on our servers.
  • Works offlineOnce the page has loaded, the tool keeps working without a connection.
v4 is fully random and works everywhere. v7 starts with a timestamp, so IDs sort by creation time and keep database indexes compact.
Random. The classic choice: 122 random bits, no embedded information.Time-ordered (RFC 9562). Sorts by creation time — ideal for database primary keys.
Generate 1 to 1,000 UUIDs at once. All of them appear in the list below, ready to copy or download.

Your UUID v4

Random
000000000000000000000000000000000000

Format

How each UUID is written. Changing the format never changes the IDs themselves.
The standard 8-4-4-4-12 layout. Turn off for a compact 32-character hex string, e.g. for a BINARY(16) import or a file name.
RFC 9562 says to output lowercase but accept either case. Some Microsoft tools and older systems show GUIDs in uppercase.
The registry format Windows and .NET use for GUIDs, e.g. {3f2504e0-4f89-11d3-9a0c-0305e82c3301}.
How the batch is joined: one per line for scripts, a JSON array for code and fixtures, a CSV column for spreadsheets, or a comma list to paste into SQL IN (…).
Wrap each ID in quotes, e.g. single quotes for SQL string literals. JSON arrays always use double quotes.
Double quotes, as JSON and most languages use.Single quotes, as SQL string literals use.
A single-key shortcut that works anywhere on the page except in text fields. Turn it off if you use speech input or keyboard tools that could press R by accident.

UUIDs

Every ID in the batch, formatted with your options. Copy them all or download a file.
Copy allDownload uuid-v4.txt

UUID inspector

Paste any UUID or GUID to see its version, variant and, for v1, v6 and v7, the moment it was created.
Clear
Works with any version, with or without hyphens, braces or a urn:uuid: prefix. Nothing leaves your browser.

Need a secure web app built around this? Talk to our team

Quick answer

A UUID (universally unique identifier) is a 128-bit value written as 32 hex digits in an 8-4-4-4-12 pattern, such as 017f22e2-79b0-7cc3-98c4-dc0c0c07398f. Version 4 is fully random; version 7 starts with a millisecond timestamp, so it sorts by creation time. In Playxoft's UUID generator, pick a version, choose how many you need, and copy or download them. Every UUID is generated locally by your browser's cryptographic random number generator.

  • Version 4 and 7
  • Bulk up to 1,000
  • Monotonic v7 ordering
  • JSON, CSV and SQL lists
  • UUID inspector
  • Timestamp decoding
  • Copy and download

How to use the UUID Generator

  1. 1Choose Version 4 for a fully random UUID or Version 7 for one that sorts by creation time.
  2. 2Set How many you need, from 1 to 1,000. A fresh batch appears instantly; click Generate new or press R for another.
  3. 3Adjust the Format: hyphens, uppercase, braces, quotes and a list layout such as a JSON array, a CSV column or a SQL list.
  4. 4Click Copy for the highlighted UUID, or Copy all and Download for the whole batch.
  5. 5Paste any UUID into the UUID inspector to read its version, variant and embedded timestamp.

What is a UUID?

A UUID is a 128-bit identifier that any computer can create on its own, with no central registry, and still be practically certain nobody else will ever create the same one. The format is defined by RFC 9562, which replaced the older RFC 4122 in May 2024. Microsoft calls the same thing a GUID.

It is written as 32 hexadecimal digits in five groups, 8-4-4-4-12. Two digits carry metadata:

  • The 13th digit is the version: the 7 in 017f22e2-79b0-7cc3-… means version 7.
  • The 17th digit holds the variant. For standard UUIDs its top two bits are 10, so it is always 8, 9, a or b.

The version says how the other bits were made:

VersionHow it is builtWhen to use it
v160-bit timestamp (100 ns ticks since 1582) + clock sequence + node, often the MAC addressLegacy only: it leaks the creating host and time
v3MD5 hash of a namespace UUID plus a nameDeterministic IDs from names; prefer v5
v4122 random bitsOpaque IDs where creation time should stay private
v5SHA-1 hash of a namespace UUID plus a nameThe same name always maps to the same UUID
v6v1's fields reordered so the timestamp sorts firstSystems already built on v1; otherwise use v7
v748-bit Unix timestamp in milliseconds + random bitsDatabase keys and anything sorted by creation
v8Custom layout; only the version and variant bits are fixedVendor-specific formats

Version 2 (DCE Security) exists but is almost never used.

RFC 9562 also defines two special values: the nil UUID (all zeros), meaning "no value", and the max UUID (all f), a sentinel for things like range bounds. Paste either into the inspector above to see them recognized.

UUID v4 vs v7: which should I use?

Both are 128 bits and both are safe to generate anywhere. The difference is what fills the bits.

UUID v4UUID v7
Contents122 random bits48-bit Unix timestamp (ms) + 74 random bits
Sort orderRandomCreation time
Database index insertsScattered across the whole B-treeAppended near the end, like an auto-increment
RevealsNothingWhen it was created, to the millisecond
Built inEverywhere (crypto.randomUUID, uuid.uuid4)Newer runtimes: Python 3.14, PostgreSQL 18, .NET 9

Use v7 for database primary keys and anything you sort or paginate by. Random v4 keys land on random pages of a B-tree index, so a large table suffers page splits and poor cache locality on every insert; v7 keys arrive in roughly ascending order, so new rows go to the same "hot" pages, much like a sequential integer key.

Use v4 when the ID is public and its creation time should stay private, for example a share link or an external reference. Anyone can read a v7's timestamp; paste one into the inspector to see it.

How does UUID v7 stay sorted within one millisecond?

A millisecond is a long time for a computer: this page can make a thousand v7 UUIDs inside one. If the bits after the timestamp were purely random, UUIDs from the same millisecond would sort in a random order.

RFC 9562 §6.2 describes several fixes. This generator uses method 1, a dedicated counter: the 12 bits after the version digit (rand_a) start at a random value with the top bit clear, and each UUID created in the same millisecond adds one. The rest stays random. Two edge cases are handled the way the RFC allows:

  • If the counter would overflow, the timestamp is advanced by one millisecond.
  • If the system clock jumps backwards, the last timestamp is reused, so the sequence never goes down.

Monotonic ordering is guaranteed per generator. UUIDs made on different machines in the same millisecond interleave in random order, which is still close enough to time order for indexes.

Can two UUIDs ever collide?

In theory yes, in practice no. A v4 UUID has 2^122 possible values (about 5.3 × 10^36). By the birthday bound, you would need roughly 2.7 quintillion (2.7 × 10^18) v4 UUIDs before the chance of even one duplicate reaches 50%.

Real-world duplicates come from broken randomness, not from the math: a Math.random() polyfill, two virtual machines restored from the same snapshot, or a forked process that copies its parent's generator state. Browsers' crypto.randomUUID() and crypto.getRandomValues(), which this tool uses, are cryptographically secure. To estimate risk for shorter IDs, try the collision calculator in the nanoid generator.

How should I store UUIDs in a database?

Store the 16 bytes, not the 36-character string. A native type is smaller, faster to compare and validates input for free:

  • PostgreSQL: the uuid type (16 bytes). gen_random_uuid() makes v4; PostgreSQL 18 adds uuidv7().
  • SQL Server: uniqueidentifier. Note that it sorts by the last group first, so v7 values do not sort by time there.
  • MySQL: BINARY(16) with UUID_TO_BIN() and BIN_TO_UUID().

In .NET, Guid.ToByteArray() writes the first three groups little-endian. When exchanging raw bytes with other systems, use ToByteArray(bigEndian: true) (.NET 8 and later).

How do I generate a UUID in code?

Most platforms have v4 built in, and v7 support is arriving quickly:

// JavaScript (browsers and Node.js 19+)
crypto.randomUUID();                // v4

# Python
import uuid
uuid.uuid4()                        # v4
uuid.uuid7()                        # v7, Python 3.14+

// Go — github.com/google/uuid
uuid.New()                          // v4
uuid.NewV7()                        // v7, returns (UUID, error)

// C# (.NET 9+)
Guid.NewGuid();                     // v4
Guid.CreateVersion7();              // v7

-- PostgreSQL
SELECT gen_random_uuid();           -- v4
SELECT uuidv7();                    -- v7, PostgreSQL 18+

Generating the ID in your application rather than the database lets you know it before the insert, which simplifies creating related rows and retrying requests safely.

Frequently asked questions

Yes. GUID (globally unique identifier) is Microsoft's name for the same 128-bit format. Windows and .NET often display GUIDs in uppercase and wrapped in braces, which this tool can do, but the underlying value is identical.
Version 4 UUIDs come from crypto.randomUUID and version 7 from crypto.getRandomValues, the browser's cryptographically secure random generator. With 122 random bits you would need about 2.7 quintillion v4 UUIDs for a 50% chance of a single duplicate.
Yes. Its first 48 bits are the creation time in Unix milliseconds, readable by anyone who has the ID. Paste one into the inspector to see it. If creation time is sensitive, expose a version 4 UUID instead.
Avoid it. A v4 UUID is hard to guess, but tokens deserve a dedicated generator producing 128 to 256 random bits, such as crypto.getRandomValues encoded as Base64url. Never use v1, v6 or v7 UUIDs as secrets, because their timestamps make part of the value predictable.
The nil UUID is all zeros: 00000000-0000-0000-0000-000000000000. RFC 9562 reserves it to mean no value, much like null. Its counterpart, the max UUID made of all f characters, is reserved as a sentinel such as an upper bound.
RFC 9562 says to output lowercase and to accept either case on input, so comparisons should be case-insensitive. Uppercase is common in Microsoft tools. Use whatever your system expects, and normalize before comparing UUIDs as strings.
No. Every UUID is generated in your browser and is never uploaded, logged or stored. The tool keeps working offline once the page has loaded.

Last updated by the Playxoft engineering team.

From the engineers who built this tool

Building something bigger than a quick fix?

Auth, payments, dashboards and security are where web apps get hard. We have shipped them many times. Share your idea and we will map out a realistic plan and estimate, free and with no obligation.

More free tools

See all tools

Nanoid Generator

Generate nanoid IDs with any alphabet and length, and check how long until a collision.

Open tool

ULID Generator

Generate sortable ULIDs in bulk, decode their timestamps and convert them to UUIDs.

Open tool

JWT Decoder

Decode JWTs, explain every claim and expiry, verify signatures and sign new tokens.

Open tool

Base64 Encoder and Decoder

Encode text or files to Base64 and back, with Base64url, data URIs and type-detected downloads.

Open tool

URL Encoder and Decoder

Percent-encode or decode URLs and query values, and inspect every parameter.

Open tool

Hash Generator

MD5, SHA-1, SHA-256, SHA-384 and SHA-512 for text or files, with HMAC and checksum verify.

Open tool