Short random nanoid IDs with your own length and alphabet, and the collision odds
Runs in your browser. Nothing you type is sent anywhere. Updated on 24 Oct 2026.Nanoid makes short random IDs for URLs, file names and database keys: 21 URL-safe characters by default, carrying 126 random bits, a little more than the 122 in a UUID v4. Choose the length and the alphabet, such as digits only or no lookalike characters, and the page estimates how many IDs you could create before a 1% chance of a duplicate. Values use the same unbiased method as the nanoid library.
The page opens with nanoid selected under Type, at 21 characters.
Set Length and pick an Alphabet, or choose Custom and type your own characters.
Read the note under the result for how many IDs give a 1% chance of a duplicate.
Set How many, click Generate, then Copy.
This UUID generator creates version 4 and version 7 UUIDs in your browser, from one to a thousand at a time. Choose uppercase, no hyphens or curly braces, then copy the list or download it as a text file. Paste any UUID into the checker to see whether it is valid, which version it is, and when it was made if the version records a time.
Version 4 values come from crypto.randomUUID. Version 7 values follow RFC 9562: 48 bits of milliseconds, the version and variant bits, a counter and random bits from crypto.getRandomValues. Within the same millisecond the counter increases, so every UUID in a batch is larger than the one before, even when you generate a thousand at once.
Two alternatives are built in. A ULID is 26 characters of Crockford base32, a millisecond timestamp followed by 80 random bits, and sorts as text; the monotonic option keeps IDs from one millisecond in order. A nanoid is a short random string, 21 URL-safe characters by default, with your own length and alphabet and an estimate of the collision odds. The checker decodes a ULID's time as well as a UUID's.
The rest of the article, and all 6 questions about UUID Generator, are on the UUID Generator page.
Version 4 is entirely random apart from the version and variant bits. Version 7 starts with the time in milliseconds, then adds random bits, so v7 UUIDs sort in the order they were created. Use v7 for database primary keys, v4 when the order must not reveal anything.
In practice, yes. A v4 UUID has 122 random bits; you would need to generate billions per second for many years before a collision became likely. Version 7 adds a millisecond timestamp and a counter, which makes a clash within one generator impossible.
A ULID suits database keys and logs that should sort by time as plain text, in 26 characters instead of 36. A nanoid suits short IDs in URLs or file names, where a timestamp is not wanted. Use a UUID when a schema, an API or a database column type expects one.
No. They are generated in your browser with its secure random number generator and are never sent or stored. Only your options, such as uppercase or the number to generate, are remembered on this device.
Still stuck? Ask about UUID Generator and anybody who knows can answer. No account needed.
Same job, other tools: Fake Address Generator (India) – Indian test addresses with a real city, state and PIN code, on streets that do not exist · Random IP Address Generator – IPv4 addresses for logs and tests, drawn only from the ranges reserved for documentation.
On the related tools: Remove Tracking Parameters – Strip utm, fbclid and gclid from a link before you share it.
In the collection Test Data Generators.