Free · Private · Client-side
OpenSSL rand -hex 32 Generator
Generate the same kind of random hexadecimal string that openssl rand -hex 32 prints in a terminal: 16, 32 or 64 cryptographically random bytes encoded as hex, created in your browser.
Generated values never leave this device.64 chars, 0-9 a-fIn plain terms: a gaming PC guessing a million passwords per second would need 132,943,112,026,157,700,000,000,000,000,000,000 quintillion times the age of the universe. Even someone renting every cloud server on Earth — a trillion guesses per second — would need 132,943,112,026,157,700,000,000,000,000 quintillion times the age of the universe. Nobody is guessing this password; the only realistic risks are it being reused or phished.
Generated hex strings
The matching OpenSSL commands
Both commands read 32 random bytes from OpenSSL's CSPRNG. The only difference is how those bytes are printed: hex gives 64 characters, Base64 gives 44.
32 bytes as 64 hex characters
openssl rand -hex 3232 bytes as 44 Base64 characters
openssl rand -base64 32Python equivalent
python3 -c "import secrets; print(secrets.token_hex(32))"Node.js equivalent
node -e "console.log(require('crypto').randomBytes(32).toString('hex'))"What openssl rand -hex 32 does
randasks OpenSSL for cryptographically secure random bytes32is the number of bytes, not characters — 32 bytes is 256 bits of entropy-hexprints each byte as two hexadecimal digits, so you get a 64-character string-base64prints the same bytes as Base64 instead, a shorter string that can contain+,/and=- Need a different length?
openssl rand -hex 16gives 32 characters (128 bits) andopenssl rand -hex 64gives 128 characters (512 bits)
Common Uses
# Any secret that wants a random hex value
SECRET_KEY=...
# Encryption key (32 bytes = AES-256)
ENCRYPTION_KEY=...
# Webhook or signing secret
WEBHOOK_SECRET=...Hex or Base64?
- Hex is safe to paste anywhere: only 0-9 and a-f, no symbols to escape in shells, URLs or config files
- Base64 is about a third shorter but can include
+,/and= - Pick by what the receiving software expects — the entropy is identical for the same byte count