lans.cloud Tools

UUID Generator

Free UUID v4 generator. Create one or up to 500 random UUIDs with uppercase and no-hyphen options, generated locally with cryptographic randomness.

Was this tool helpful?
Support this site

More tools

How to generate a UUID

Four steps, and every ID is created in your browser rather than fetched from a server.

  1. Choose how many you need

    Enter a count between 1 and 500. One is the common case; a batch is useful when you are seeding a test database or pre-allocating IDs for a migration. The button and the result heading both follow the count.

    The Generator Options card with 8 in the how-many box, the two format switches at their defaults, and a button reading Generate 8 UUIDs
  2. Set the formatting to match where it is going

    Turn hyphens off if the destination stores the 32-character compact form, and turn uppercase on if you are matching an existing system. The batch re-generates the moment you flip either one. The canonical RFC form is lowercase with hyphens, so leave both alone unless something downstream requires otherwise.

    Uppercase switched on and Include hyphens switched off, with the eight results below them now in the 32-character compact uppercase form
  3. Generate and copy, or download the batch

    "Copy all" puts the whole batch on the clipboard, which with a count of 1 is simply the one UUID, and Download gives you a text file with one per line. Everything is generated in your browser by the platform's cryptographic random number generator, so no ID is ever transmitted or logged.

    The results card after Copy all was pressed: the button now reads Copied! with a tick, beside the Download button, above the eight generated IDs
  4. Check it is the right version for the job

    This generator makes v4, which is random and therefore unordered. If the ID is going to be a database primary key, read the storage table below first, because a random key and a clustered index interact badly.

    The UUID versions table comparing v1, v4, v5 and v7, with the v4 row marked as what this generator produces and a note about collision odds

Generate v4 UUIDs Instantly

This free UUID generator creates version-4 UUIDs (RFC 9562, which replaced RFC 4122 in 2024) (also known as GUIDs) — singly for a quick copy-paste, or in bulk up to 500 at a time for test data and database seeding. Everything is generated locally in your browser with cryptographic randomness; nothing is requested from or sent to a server.

Where UUIDs Are Used

  • Database primary keys — IDs that can be generated on any client or server without coordination and merged later without conflicts.
  • API request and correlation IDs — trace a request across microservices by tagging it once at the edge.
  • File and resource names — collision-proof names for uploads, temp files, and S3 objects.
  • Test fixtures — realistic unique identifiers for seeding development and staging environments.

Anatomy of a v4 UUID

A UUID like 550e8400-e29b-41d4-a716-446655440000 is 32 hexadecimal digits in five groups (8-4-4-4-12). In version 4, the first digit of the third group is always 4 (the version), and the first digit of the fourth group is 8, 9, a, or b (the variant). The remaining 122 bits are pure randomness — that immense space is what makes collisions practically impossible.

UUIDs are case-insensitive by specification: ABC… and abc… refer to the same identifier. Lowercase with hyphens is the canonical text form; use the toggles if your system expects uppercase or unhyphenated storage.

UUID versions compared

VersionBuilt fromWhen to use it
v1Timestamp + MAC addressSortable by creation time; leaks machine identity — largely superseded
v4Random (122 random bits)The default everywhere; what this generator produces
v5SHA-1 hash of a nameDeterministic: same input, same UUID — for stable derived IDs
v7Unix timestamp + randomSortable AND private — the modern choice for database keys

This tool generates v4 — with 122 random bits you'd need ~2.7 quintillion UUIDs for a 50% chance of a single collision.

Storing a UUID: four options and what each costs

Stored asBytes per valueWhat you trade
Canonical text, 36 chars36 bytes (plus overhead)The default in most ORMs. Readable in a query result, and the most expensive option at scale: every index entry carries all 36 bytes.
Compact text, 32 chars32 bytesHyphens stripped. Saves four bytes per row and loses the visual grouping; convert on the way in and out or you will end up with both forms in one column.
Native uuid type16 bytesPostgreSQL has a real uuid type and it is the right answer there. Compact, still readable in results, and comparisons stay correct.
BINARY(16)16 bytesThe MySQL equivalent, since it has no native type. Halves the storage against text but the column is unreadable without BIN_TO_UUID(), or HEX() for the compact form. Note MariaDB 10.7+ does have a native UUID type.

Sizes assume a single-byte or ASCII text representation and ignore per-row and per-index overhead. In MySQL, CHAR(36) under the default utf8mb4 charset counts as 144 bytes against index-length limits and in in-memory temp tables, though InnoDB's COMPACT and DYNAMIC row formats store the value itself in 36 bytes by trimming trailing spaces. Declaring the column CHARACTER SET ascii makes 36 bytes hold everywhere. The gap matters most in indexes, where the key is repeated in every entry.

Choosing a primary key: why insert ORDER is the deciding factor

Key typeInsert orderWhat actually happens
Auto-increment integerSequentialEvery insert lands at the end of the index, so the hot pages stay in memory. Smallest and fastest, but the IDs are guessable and they leak how many rows you have.
UUID v4 (this tool)RandomEvery insert lands in a random position, so a clustered index (InnoDB, and SQL Server by default) splits pages and fragments as the table grows. Fine for modest tables, and genuinely painful at high insert volume.
UUID v7Time-orderedA Unix millisecond timestamp followed by random bits, so inserts are near-sequential again while staying unguessable. Standardised in RFC 9562 (2024), which supersedes RFC 4122.
ULIDTime-orderedSame idea, predating v7, encoded in Crockford base32 so it is 26 characters and case-insensitive. Widely used, but it is a community spec rather than an IETF one.

The problem with a random key is never that it is slow to generate — it is where in the index each row lands. A time-ordered ID (v7 or ULID) keeps the unguessability and removes the fragmentation, which is why new systems tend to pick one of those over v4.

Frequently Asked Questions

What is a UUID?

A UUID (Universally Unique Identifier, also called a GUID) is a 128-bit identifier written as 36 characters, like 550e8400-e29b-41d4-a716-446655440000. Version 4 UUIDs are generated from random data, making collisions so unlikely they are treated as impossible in practice.

Are these UUIDs really unique?

A v4 UUID contains 122 random bits, giving about 5.3 undecillion possible values. You would need to generate roughly a billion UUIDs per second for 85 years to reach even a 50% chance of a single collision — which is why they are used as database keys and request IDs everywhere.

Is the generation cryptographically secure?

Yes. UUIDs come from your browser’s crypto API (crypto.randomUUID / getRandomValues), the same cryptographic randomness source password managers use — not from Math.random. Generation happens entirely on your device.

Can I generate UUIDs in bulk?

Yes — up to 500 at a time, one per line. Copy them all with one click or download them as a text file for seeding databases, test fixtures, or spreadsheets.

What are the uppercase and no-hyphen options for?

Some systems store or compare identifiers in uppercase (e.g. some Microsoft tooling) or as 32-character hex strings without hyphens (e.g. certain APIs and database columns). The toggles format the output to match whatever your system expects.

UUID v4 generator showing a freshly generated identifier with uppercase and hyphen options
Cryptographically random v4 UUIDs — single or up to 500 at once, formatted your way.