UUID Generator

A free tool by DeepRit, a Google Ads agency that does PPC and nothing else. We build and run Google Ads accounts so every click is accounted for. Book a free audit call

Free UUID generator. Create random version 4 or time-ordered version 7 UUIDs in bulk, and check the version and timestamp of any UUID.

UUIDs
Valid
0
Version
0
Variant
0
Created
0

Free, no sign-up. Runs in your browser: nothing you type is uploaded or saved.

How to use the UUID generator

Choose a version and how many UUIDs you need (up to 1,000), and the UUID generator creates them instantly, one per line, ready to copy:

  • Version 4 (random): the most widely used kind. 122 random bits.
  • Version 7 (time-ordered): starts with a timestamp, so UUIDs sort in the order they were created. Ideal for database keys.

Formatting options: upper case, hyphens on or off, and braces { } around each one (the format some Microsoft tools use). Click Generate for a fresh batch.

To check an existing UUID, paste it under "Check a UUID". You'll see whether it's valid, its version, its variant and, for version 1 and version 7 UUIDs, when it was created.

UUIDs are generated in your browser with its cryptographically secure random number generator. Nothing is sent anywhere, and we never see them.

What is a UUID?

A UUID (universally unique identifier), also called a GUID (globally unique identifier) in the Microsoft world, is a 128-bit number used to identify something uniquely without a central authority handing out numbers. It's written as 32 hexadecimal digits in five groups:

f47ac10b-58cc-4372-a567-0e02b2c3d479

The groups have 8, 4, 4, 4 and 12 digits. One digit shows the version (the 4 at the start of the third group above), and the first digit of the fourth group shows the variant (8, 9, a or b for standard UUIDs).

UUIDs are defined in RFC 9562 (published in 2024, replacing the older RFC 4122), which added versions 6, 7 and 8.

Version 4 vs version 7

Version 4: random

A version 4 UUID is 122 random bits, plus 6 fixed bits for the version and variant. It reveals nothing about when or where it was made. It's the default choice for most uses: IDs for records, files, sessions, API requests and test data.

Version 7: time-ordered

A version 7 UUID starts with a 48-bit Unix timestamp in milliseconds, followed by 74 random bits. Because the timestamp comes first, version 7 UUIDs sort by creation time. That matters for databases: random version 4 keys are inserted all over a database index, which slows writes on large tables, while version 7 keys go in order. Version 7 is now recommended for new database primary keys.

The trade-off: anyone who sees a version 7 UUID can read when it was created. Don't use it where that's sensitive. UUIDs made in the same millisecond share a timestamp and are ordered randomly within it.

Other versions

  • Version 1: a timestamp plus the generating computer's network (MAC) address. Largely replaced, because it can reveal the machine.
  • Versions 3 and 5: made by hashing a name (with MD5 or SHA-1), so the same name always gives the same UUID.
  • Version 6: a reordered version 1 that sorts by time.
  • Version 8: a format for custom, application-specific UUIDs.

The checker in the UUID generator recognises them all.

Can two UUIDs ever be the same?

In theory, yes; in practice, no. A version 4 UUID has 2¹²² possible values, about 5.3 × 10³⁶. You'd need to generate about 1 billion UUIDs every second for around 85 years to have a 50% chance of a single duplicate. As long as the random number generator is good, which the browser's cryptographic generator is, you can treat UUIDs as unique.

UUIDs are not secrets

UUIDs are unique, but they're not designed as passwords or security tokens:

  • Version 1, 6 and 7 UUIDs contain a timestamp.
  • Unique doesn't mean hard to guess in every implementation.
  • UUIDs often appear in URLs, logs and analytics.

For passwords, use the password generator. For tokens, use your framework's dedicated secure token functions.

Using UUIDs

  • Databases: as primary keys, especially when records are created in many places (several servers, mobile apps offline) and merged later.
  • APIs: request IDs for tracing a request through logs.
  • Files and uploads: unique file names that never clash.
  • Distributed systems: IDs created without asking a central server.
  • Testing: realistic IDs for test data and fixtures.
  • Analytics: anonymous visitor or session IDs.

Storing UUIDs

In databases, store UUIDs in a native UUID type where available (PostgreSQL's uuid, for example) or as 16 bytes of binary, not as a 36-character string: it's less than half the size and faster to index.

UUIDs in code

Most languages can generate UUIDs:

  • JavaScript (browsers and Node.js): crypto.randomUUID() creates a version 4 UUID.
  • Python: uuid.uuid4(); recent versions also have uuid.uuid7().
  • PostgreSQL: gen_random_uuid(); version 18 and later also has uuidv7().
  • Java: UUID.randomUUID().
  • .NET: Guid.NewGuid(); .NET 9 and later also has Guid.CreateVersion7().

The UUID generator is handy when you need a few UUIDs right now: for a config file, a test, a database row or documentation.

UUIDs vs auto-increment IDs

Many databases number rows 1, 2, 3 automatically. That's simple and compact, but:

  • Numbers are guessable. If an order page is /orders/1042, anyone can try /orders/1043. UUIDs aren't sequential (version 4) or guessable at a glance, though you should still check permissions properly.
  • Numbers need a central counter. Two servers, or an app working offline, can't safely create IDs without coordinating. UUIDs can be created anywhere.
  • Numbers reveal volume. Order number 1042 tells a competitor roughly how many orders you've had.

Auto-increment IDs are smaller (4 or 8 bytes against 16) and slightly faster, so they're still a good choice for internal tables. Version 7 UUIDs give most of the benefits of both: created anywhere, but ordered by time.

Formatting options explained

  • Hyphens: the standard format has them. Some systems store UUIDs as 32 hex characters without hyphens; they're the same value.
  • Upper case: UUIDs are case-insensitive. The standard recommends lower case for output, but some systems, such as older Microsoft tools, display upper case.
  • Braces: Windows registry keys and some .NET and COM code show GUIDs in braces, like {f47ac10b-58cc-4372-a567-0e02b2c3d479}.

The UUID checker accepts all of these formats, and the urn:uuid: prefix too.

Nil and max UUIDs

Two special UUIDs are defined: the nil UUID, all zeros (00000000-0000-0000-0000-000000000000), often used to mean "no value", and the max UUID, all f's. The checker recognises both.

UUIDs in URLs and file names

UUIDs are URL-safe as they are: they only contain letters, digits and hyphens. In URLs, lower case with hyphens is the most readable. For file names, UUIDs guarantee no clashes, but they aren't descriptive, so many systems combine them with a readable name, like "invoice-2026-11-f47ac10b.pdf", using the first part of the UUID.

How the UUID generator creates UUIDs

For each UUID, the generator asks your browser for 16 random bytes from its cryptographic random number generator (the same source used for encryption keys), then sets the version and variant bits as the standard requires. For version 7, the first 6 bytes are replaced with the current time in milliseconds. Nothing is sent to a server, so no one else ever sees the UUIDs you create.

A worked example

A bakery's developer is adding online orders to the shop's system, and orders are created both on the website and on a tablet in the shop that sometimes works offline. To avoid clashing order numbers, every order gets a UUID. The developer uses version 7 so orders sort by time in the database, generates 20 in the UUID generator for test data, and pastes one into the checker: it shows version 7 and the exact time it was created. In production, the app generates its own UUIDs with the same standard.

Need more customers from Google?

This tool is free and runs in your browser. If your business also needs more leads or sales, Google Ads is where people search with their wallet out. That is the whole job of DeepRit: a PPC-only agency that sets up and runs Google Ads accounts so every click is accounted for. You keep full ownership of your account, get a written report every week, and can stop at any time. See our pricing or ask for a free audit.

Frequently asked questions

How do I generate a UUID?

Choose version 4 or version 7 in the UUID generator, set how many you need, and copy them. Click Generate for a new batch.

What's the difference between a UUID and a GUID?

They're the same thing. GUID is Microsoft's name for a UUID.

Should I use UUID version 4 or version 7?

Version 4 for general unique IDs. Version 7 for database keys, because it sorts by creation time and keeps indexes efficient.

Can a UUID be duplicated?

The chance is so small it can be ignored: you'd need about a billion UUIDs a second for 85 years for a 50% chance of one duplicate.

Are UUIDs secure?

They're unique, not secret. Don't use them as passwords or security tokens.

Is the UUID generator free?

Yes. It's free with no sign-up, and UUIDs are created in your browser.

Free PPC audit

See where your ad budget leaks.

We look at your Google Ads account before the call, then walk you through what we'd fix first, in dollars. No obligation, no hard sell.

Book a free audit call 30-minute call · Free · The audit is yours to keep