What are base64, base32, base58, hex and when to use them?
Computers see bytes, humans and protocols prefer text. Hence encodings: ways to write raw bytes as readable numbers and letters. Here you convert both ways between 8 formats:
- UTF-8 text (plain string),
- hex,
- Base32,
- Base58,
- Base64 (standard, 64-character alphabet with +/= padding),
- Base64URL,
- binary (0s and 1s, 1 byte = 8 bits),
- decimal (decimal value of each byte).
Live conversion both ways as you type. Each format has its own validation: type an invalid character and you see an inline red error instantly.
Everything runs in your browser. Your data never leaves the device.
How to use
- On the left pick a source format and paste/type your data. On the right pick a target format and watch the conversion happen instantly.
- You can also edit the right side, the left will reflect the change. Two-way live conversion.
- The swap button (arrows in the middle) flips source and target.
- Below: examples per format. Click one to load the example into the source.
- Validation: Base58 rejects "0", "I", "O", "l" (visually confusing). Hex accepts only 0-9 and a-f. Binary accepts only 0 and 1. If you paste something else, you see an inline red error.
When to use it
Six common situations where a base converter is useful:
- Debugging an API payload. An API key in base64 (from .env) gets converted to hex so you can count the bytes.
- TOTP secrets (Google Authenticator, Authy). The secret is in Base32. Paste it, get hex/bytes, verify the length (should be 20 bytes = 160 bits for SHA-1).
- Bitcoin / Solana address. Bitcoin uses Base58Check. Convert to hex to inspect the underlying public key hash.
- Binary data in JSON. JSON cannot hold binary, it uses base64. Convert a JSON value to bytes to verify the format.
- CTF, reverse engineering. Flags often come encoded in layers. Paste, click through formats, find the answer.
- Crypto debugging. A PEM key is base64 inside. Decode and count the bytes to sanity-check.
To encrypt data instead of just encoding, use AES encryption. To sign a JWT see the JWT signer.