UUID / GUID Generator

How do I generate a UUID?

Result

f3186b0a-758f-4cb6-b6e5-ed291525cbc7

How it is calculated

The tool asks the system's cryptographic random source for 16 bytes per UUID, then overwrites two fields so the value is a valid version 4 identifier: the high nibble of byte 7 is set to 4 (the version) and the top two bits of byte 9 are set to 10 (the variant). The remaining 122 bits are pure randomness. The bytes are written as 32 hexadecimal digits in the 8-4-4-4-12 pattern xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx, where y is always 8, 9, a or b.

The count field is the number of UUIDs (a whole number). Empty means 1, and anything above 20 is capped at 20, below 1 raised to 1. One UUID is printed per line, in lowercase. Nothing is stored, so every run gives new values.

Worked example

Entering count = 1 returns one line of 36 characters; with 3 you would get three such lines. Because the values are random, your output will differ from anyone else's and from a previous run; a sample run on 2026-10-17 looked like 7797865f-31b5-4901-8d57-15311dc76ab9. Check the pattern, not the digits: the first group has 8 hex digits, the third group starts with 4, and the fourth group starts with 8, 9, a or b. Entering 50 would still give only 20 lines.

Try this example →

Common mistakes

  • Treating a UUID as a secret. It is an identifier; a v4 value is unpredictable, but do not use it as a password or access key on its own.
  • Expecting the same UUID twice. Each press generates fresh values, so copy the ones you need before running again.
  • Asking for more than 20 at once and assuming you got them all. The count is capped at 20 per run.
  • Comparing UUIDs case-sensitively. They are shown in lowercase here, but systems that print uppercase hold the same value; normalise case before matching.
  • Removing hyphens when the target system expects the 36-character form (or the reverse). Check whether your database column or API wants the dashed or compact form.

About this calculator

This tool generates one or more random UUIDs (Universally Unique Identifiers), specifically version 4, which is built almost entirely from random bits formatted into the standard 36-character pattern like xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx. The chance of two version-4 UUIDs ever colliding is astronomically small, which is what makes them usable as unique identifiers without needing a central authority to hand them out or check for duplicates.

It is used by software developers assigning unique IDs to database rows, API resources, session tokens, or file names where a simple incrementing number either isn't available or would leak information (like how many records exist). QA engineers and testers also generate them on the fly to create realistic-looking unique test data without having to invent IDs by hand.

Was this helpful?

You can pick up to 3 reactions.

Comments (1)

  • Editorial team

    The tool produces version 4 identifiers from random bytes, between one and twenty per request, and each reload gives a fresh set. They are generated on our server, so for anything secret such as access tokens or keys, generate them in your own environment instead. For test data, seed scripts and placeholder IDs they work fine. Which output format would help you, uppercase, no hyphens or curly braces?

Popular calculators

All Calculators