Base32 Encoder
Free online base32 encoder and decoder. Convert plain text to Base32, or decode a Base32 string back to readable text — instantly, with no file leaving your device.
All encoding and decoding runs locally in your browser. No text or files are uploaded, stored, or transmitted to any server.
How the Base32 Encoder Works
Every 8-bit byte of your text is regrouped into 5-bit chunks, and each chunk maps to one letter of the Base32 alphabet. For example, encoding HI:
Result: HI → JBEQ====
How to Use the Base32 Encoder Tool
.txt file.
What Is Base32 Encoding?
Base32 encoding is a binary-to-text scheme, defined in RFC 4648, that represents binary data using a 32-character alphabet: the letters A–Z and the digits 2–7. Because the alphabet is small and case-insensitive, Base32 output is easy to read aloud, type by hand, or use in systems — like DNS records or two-factor authentication secrets — that don't distinguish uppercase from lowercase. Base32 is an encoding, not encryption: it doesn't hide or protect your data, since no key is required to reverse it.
How Does the Base32 Encoder Work?
This base32 encoder reads your text as UTF-8 bytes, regroups every 8 bits into 5-bit chunks, and maps each chunk to a character in the Base32 alphabet. When the input length doesn't divide evenly, the final group is padded with = characters so the output always ends on an 8-character boundary — fully RFC 4648 compliant, and reversible with the matching decoder built into this same tool.
Base32 Encoding vs Base64: Key Differences
| Base32 | Base64 |
|---|---|
| 32-character alphabet: A–Z, 2–7 | 64-character alphabet: A–Z, a–z, 0–9, +, / |
| Case-insensitive, human-friendly | Case-sensitive; more compact output |
| ~1.6× size expansion | ~1.33× size expansion |
| Common in DNS labels, TOTP secrets | Common in email attachments, data URIs |
Common Use Cases for Base32
- Encoding two-factor authentication (TOTP) secret keys
- Representing binary identifiers in DNS-safe or filesystem-safe text
- Generating short, case-insensitive tokens or codes
- Converting arbitrary binary data to ASCII for logs or transport
Why Use Our Base32 Encoder Tool?
This base32 encoder is fully client-side: your text and files are processed entirely in your browser and never uploaded to a server. It's mobile-friendly, ad-free within the tool itself, supports full UTF-8 text and file uploads, and pairs encoding with a matching, RFC 4648-compliant decoder — so you can convert in either direction from the same page.
How to Convert a String to Base32 Encoding in JavaScript
You can implement Base32 encoding yourself with native JavaScript, using TextEncoder to get UTF-8 bytes and a custom RFC 4648 alphabet lookup — the same approach powering this tool:
function encodeBase32(str) {
const ALPHABET = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ234567';
const bytes = new TextEncoder().encode(str);
let bits = '';
for (const b of bytes) bits += b.toString(2).padStart(8, '0');
let output = '';
for (let i = 0; i < bits.length; i += 5) {
let chunk = bits.substring(i, i + 5).padEnd(5, '0');
output += ALPHABET[parseInt(chunk, 2)];
}
while (output.length % 8 !== 0) output += '=';
return output;
}
Frequently Asked Questions
=) is added to complete the final group when needed.TextEncoder and a custom Base32 alphabet mapping, as shown in the JavaScript example above. This tool provides both encoding and decoding without any server calls.Encode and decode Base32 instantly — secure, private, mobile-friendly, and 100% client-side. No uploads, no servers, no tracking.
0 Comments