Developer / IDs

Nano ID Generator

Generate random, URL-safe IDs like Nano ID with any alphabet and length, many at once, and see how long it takes before a collision becomes likely.

Nano ID Generator: Each character is drawn from the browser's secure random generator and mapped onto the alphabet with a bitmask, rejecting values that fall outside it, the method the nanoid library uses so every character is equally likely. The default, 21 characters of 64, is about as collision-resistant as a UUID v4 in a shorter, URL-safe form. The estimate uses the birthday bound for a 1% chance of any two IDs matching. Runs 100% locally in your browser with zero server file uploads.

Runs
In your browser
Cost
Free · no sign-up
Availability
Ready to use
Nano ID generatorLocal processing

Runs entirely in your browser

At 1,000 IDs an hour, about 149,000,000,000 years pass before a 1% chance of any two being the same.

Characters come from your browser's secure random generator, spread evenly over the alphabet by masking and rejection, as the nanoid library does.

Choosing a length

Each extra character multiplies the possibilities by the alphabet size: with 64 characters, 10 characters give about a billion billion IDs, enough for a small app, and 21 characters match a UUID. Shorter IDs are fine for short-lived or low-volume uses, such as share links.

For standard UUIDs, use the UUID generator; for secrets, the password generator.

IDs are not secrets

Random IDs are hard to guess, but they appear in URLs, logs, and browser history; never use an ID alone as proof of access to private data.

How to use it

  1. Choose an alphabet, such as URL-safe or digits only, or type your own.
  2. Set the length and how many IDs to make.
  3. Copy the IDs; set how many you make per hour to see the collision estimate.

Privacy & limitations

IDs are made in your browser.

Related tools

Frequently asked questions

Nano ID or UUID?

Both are random; Nano ID packs similar randomness into 21 URL-safe characters instead of 36. Use UUIDs where a database or standard expects them.

Can I use a short ID?

Yes, if you make few of them; check the collision estimate, and check new IDs against existing ones if a duplicate would cause trouble.

Why avoid look-alike characters?

For IDs that people read or type, such as order or voucher codes, leaving out 0, O, 1, l, and I prevents misreadings.

Free tool · runs in your browser · no account required