Skip to content
Zesona
NanoID GeneratorLocal

NanoID Generator

Generate compact URL-safe random identifiers with a configurable length and alphabet, and a real entropy figure.

  • Free
  • No sign-up
  • Runs in your browser

Input

Runs in your browser

Generate up to 1,000 at once.

Leave empty for the 64-character URL-safe set. Duplicates are removed.

Ready

Everything happens on this device. No upload, no account, no network request.

How to use this tool

  1. 1

    Choose how many you need and they are generated immediately.

  2. 2

    Every value comes from the browser’s cryptographically secure random generator, never Math.random.

Questions about NanoID Generator

How long should the id be?

The tool reports the actual entropy and a collision estimate for your chosen length, so you can decide from numbers rather than habit. 21 characters over the 64-symbol alphabet gives 126 bits - comparable to a UUID v4, in 15 fewer characters. For a short URL slug, 10 characters (60 bits) is usually ample.

Is a custom alphabet safe?

Yes, and the entropy figure updates to match. Index selection uses rejection sampling rather than the modulo operator, so there is no bias toward the earlier characters even when the alphabet size is not a power of two.

Is the randomness good enough to use as a secret?

The random bits come from crypto.getRandomValues, which is the platform CSPRNG - so yes for an unguessable URL token or a database key. Math.random is never used; it is seeded predictably enough that generated values can be recovered.

Is my data sent anywhere?

No. This tool runs as JavaScript inside your browser tab. There is no network request carrying your input, nothing is written to a server log, and it keeps working with your connection switched off. You can confirm it in the browser’s network panel. That matters more here than elsewhere on the site: developer tools handle tokens, keys and production data.

Does the NanoID Generator work offline?

Yes. Once the page has loaded it runs entirely as JavaScript on your own device, so the NanoID Generator keeps working with the network switched off and nothing is ever sent to a server.

Other tools you might reach for next.