Token Generator

Generate cryptographically secure random tokens for APIs, sessions, encryption, and more. Everything runs in your browser.

Tips

128 Bits Is Practically Unbreakable

A 128-bit token has 340 undecillion possible values. Even checking a trillion per second, it would take longer than the age of the universe to try them all.

Hex Is Great for Debugging

Hexadecimal tokens are easy to read in logs and config files. Each character represents exactly 4 bits, making byte boundaries visually clear.

Base58 Avoids Confusing Characters

Base58 excludes 0, O, I, and l — characters that look alike in many fonts. This makes tokens easier to copy manually without errors.

URL-Safe Tokens Need No Encoding

Standard Base64 uses + and / which must be percent-encoded in URLs. URL-safe format replaces them with - and _, and removes padding (=), so tokens work directly in query strings and paths.

Common Use Cases

🔑

API Key Generation

Create strong, unique API keys for authenticating services and applications.

🔒

Session IDs & CSRF Tokens

Generate unpredictable session identifiers and CSRF protection tokens for web applications.

🔗

One-Time Links

Create secure URL-safe tokens for password reset links, email verification, and invite URLs.

🗝️

Encryption Keys & IVs

Generate raw cryptographic material for symmetric encryption keys and initialization vectors.

🆔

Unique Identifiers

Produce random IDs as an alternative to UUIDs, with configurable length and format.

🪝

Webhook Secrets

Generate shared secrets for verifying webhook signatures between services.

Frequently Asked Questions

What is the difference between a password and a token?
A password is a human-memorizable string used for authentication. A token is a machine-generated random string used for system-to-system communication, API access, or cryptographic operations. Tokens do not need to be memorable — only unpredictable.
Should I choose 128 or 256 bits?
128 bits is sufficient for most purposes including API keys, session tokens, and unique IDs. Use 256 bits for cryptographic keys, high-security environments, or when compliance standards require it.
Which format should I use?
Use Hex for logs and debugging, Base64 for compact storage, URL-safe for web links and query parameters, and Base58 when humans need to read or copy the token manually.
Is my token sent to a server?
No. All tokens are generated entirely in your browser using the Web Crypto API (crypto.getRandomValues). Nothing is transmitted or stored.
What is Base58?
Base58 is an encoding that uses 58 alphanumeric characters, excluding 0, O, I, and l to avoid visual confusion. It was popularized by Bitcoin and is ideal when tokens are displayed to humans.
Can I use these tokens as encryption keys?
The random bytes are cryptographically secure and suitable as key material. However, for production encryption systems, use established libraries that handle key derivation, storage, and rotation properly.