Skip to content

UUID generator

Web & developer

How do you make a new UUID?

Random UUIDs, version 4 or time-ordered version 7, made on your device.

Version

UUID

–

122 random bits, version 4

Sponsored Links

Random UUIDs, version 4 or time-ordered version 7, made on your device.

How to use

  1. Choose version 4 for a random UUID, or version 7 if the UUIDs should sort by the time they were made.
  2. Copy the UUID. Press Generate again for a new one.
  3. Use the extra settings to make up to 100 at once, use upper case or add braces.

How it works

A UUID is a 128-bit label written as 32 hexadecimal digits in five groups, such as 919108f7-52d1-4320-9bac-f847db4148a8. It is made to be unique without asking anyone: two computers can create UUIDs at the same moment and still not clash, for any practical purpose. That makes them a popular key for database rows, files and messages.

A version 4 UUID is random apart from six fixed bits that mark the version and the variant, leaving 122 random bits. The chance of two matching is so small that it can be ignored. A version 7 UUID starts with the Unix time in milliseconds (48 bits) and fills the rest with random bits, so newer ones sort after older ones, which keeps database indexes tidy. Within one millisecond this tool counts up so the order holds (RFC 9562, sections 5.4, 5.7 and 6.2).

The randomness comes from your device's secure generator, never a simple formula, and the UUIDs are made in your browser and not sent anywhere. A version 7 UUID shows when it was made, so do not use it where that should stay private.

Sponsored Links

Frequently asked questions

Can two UUIDs ever be the same?

In theory yes, in practice no. With 122 random bits a repeat is astronomically unlikely, so programs treat a new version 4 UUID as unique.

Should I use version 4 or version 7?

Use version 4 when you only need a unique label. Use version 7 for database keys, where sorting by creation time helps, and when showing the creation time is not a problem.

Is a UUID the same as a GUID?

Yes. GUID is the name Microsoft uses. Windows often writes it in upper case and in braces, which are the two extra options here.

Do uppercase letters or braces change the UUID?

No. They change only how the same identifier is written.

Can I recover a creation time from a version 4 UUID?

No. Version 4 contains random bits, not a timestamp. Version 7 includes a creation timestamp.

Sponsored Links

Sponsored Links