Generators

Nano ID Generator

Generate compact, URL-safe unique IDs using a custom alphabet and size. Cryptographically secure — a modern alternative to UUID for web apps.

Free Client-Side No Sign-Up Nothing Stored
Alphabet preset
Alphabet (characters to use)
ID size
How many?

What This Tool Does

The Nano ID Generator creates compact, unique identifiers using a cryptographically secure random selection from a customisable alphabet. The default 21-character URL-safe output has the same collision probability as UUID v4 but is 31% shorter, making it ideal for database keys, URL slugs, and session identifiers in modern web applications.

Frequently Asked Questions

What is a Nano ID?
Nano ID is a tiny, URL-safe, unique string ID generator for JavaScript, created by Andrey Sitnik. It produces IDs like "V1StGXR8_Z5jdHi6B-myT" — shorter and more compact than UUIDs while being cryptographically secure. It is widely used in modern web apps as a UUID alternative.
How does Nano ID compare to UUID?
A default Nano ID (21 characters) has the same collision probability as UUID v4 (122 random bits) but is 31% shorter. Nano IDs use a URL-safe alphabet by default (A-Z, a-z, 0-9, _, -) so they can be used directly in URLs without encoding. UUIDs use a fixed format with hyphens; Nano IDs are fully customisable.
Can I customise the alphabet?
Yes — you can define any set of characters for the alphabet. Common custom alphabets include numbers-only for numeric IDs, hex characters for hash-like IDs, or reduced alphabets that avoid visually ambiguous characters.
Are Nano IDs cryptographically secure?
Yes. This generator uses crypto.getRandomValues() — the browser's cryptographically secure random number generator — to select characters, matching the security of the official nanoid library.
Is my data sent to a server?
No. Everything runs in your browser. Nothing is transmitted anywhere.