Token Generator

Cryptographically secure random tokens, your rules

Strength

About

Faq

Are these tokens cryptographically secure?

Yes. Every token uses crypto.getRandomValues() from the browser's Web Crypto API, which is a CSPRNG (cryptographically secure pseudo-random number generator). It's the same primitive used by HTTPS, password managers, and operating-system level random number generation. Math.random() is never used.

Is the generator safe for API keys and production secrets?

Yes, with one common-sense rule: do not paste the same generated token into a public URL, screenshot, or chat. Tokens are generated and shown only in your browser tab, closing the tab destroys them. For production secrets, copy directly into your secrets manager (1Password, AWS Secrets Manager, GitHub Actions secrets, Vercel env vars, etc.) and rotate periodically.

What length should I use for an API key?

32 alphanumeric characters (≈190 bits of entropy) is the modern standard for API keys and is strong enough to resist brute force essentially forever. Use 64 characters if you want headroom for very long-lived keys. For password reset tokens or short-lived session IDs, 24 characters is plenty.

What length should I use for a strong password?

16 characters with mixed case, digits and symbols gives ≈100 bits of entropy, strong enough for any account that's not protected by 2FA. For a vault master password or root account password, use 20+ characters and skip the symbols if you'll need to type it on a phone.

Why exclude similar characters like I, l, 1, O, 0?

If a human is going to read or type the token (license keys, share codes, PIN-style identifiers, recovery codes), those characters get mixed up constantly. For machine-only secrets like API keys, leave them in: more characters means more entropy.

What does no-repeat do?

It guarantees every character in the token is unique. Useful for human-readable codes where you want to avoid runs like 'AAAA', but it caps your maximum length at the size of your alphabet (e.g. 36 characters max for lowercase + digits) and reduces entropy slightly compared to allowing repeats.

Using the interactive tool

Open the canonical HTML page to use the calculator or generator. This Markdown alternate provides its complete explanatory content, labels, options, results guidance, FAQs, and limitations.