Secret Key Generator
Generate random keys in HEX, Base32 or Base64 with 128, 192 or 256 bits of entropy.
Use as an API key, a symmetric encryption key or any local secret. Do not commit it to a repository.
How to use it
- Pick an output format: HEX (compact), Base32 (URL-safe alphabet, no padding) or Base64.
- Pick a key length: 128, 192 or 256 bits. 128 bits is fine for most symmetric use; 256 for extra margin.
- Click Generate key - each click draws fresh entropy and replaces the previous key.
- Click Copy and store the key in your password manager or secret store, not in code.
Common use cases
- API keys and tokens - mint a random identifier for your own services instead of inventing one.
- Symmetric encryption - feed AES-GCM or ChaCha20 with a full-entropy key of the right size.
- Session or file identifiers - unguessable IDs for URLs, uploads or exports.
- Test fixtures - realistic-looking random material for local development without reusing real secrets.
Why it stays private
Bytes come from the browser's crypto.getRandomValues, a cryptographically secure random source. Generation happens in memory on your device; the page makes no network requests and does not persist anything.
FAQ
Q: Is this safe for production secrets? A: The random source is the same CSPRNG browsers use for session keys, so the bytes are sound. Production safety also depends on how you store the key afterwards - use a secrets manager, never a repository.
Q: Can I click Generate repeatedly until I like a key? A: You can, but every result is equally random. Re-rolling does not improve quality; it only burns entropy. Take the first key and store it properly.
Q: Why does the Base32 output have no "=" padding? A: Padding is optional for Base32 and most consumers accept unpadded strings. If your library demands padding, append the correct number of "=" characters yourself.
Your data stays on this device
Secret Key Generator runs 100% locally. Everything you paste or drop is processed by your own browser and never transmitted. Nothing is stored on our servers — close the tab and it is gone.
Nothing you type is sent to a server, logged, or used for analytics. The page works even with your network disconnected after first load.