ASCII85 / Base85 Encode & Decode — Adobe, Z85, RFC 1924 & btoa
Encode or decode across four Base85 variants — Adobe Ascii85 (PDF/PostScript), Z85 (ZeroMQ), RFC 1924 (IPv6) and btoa (Base64 for comparison) — with Base85's ~25% size advantage over Base64, file upload, and live size stats.
What is ASCII85 / Base85 Encoder & Decoder?
ASCII85 (also known as Base85) is a binary-to-text encoding that represents 4 bytes as 5 printable characters — the most space-efficient common text encoding.
Zero-Server Tool Data Guarantee
All encoding, decoding, and size math run locally in your browser. Your text and files never leave your device — no server upload, no logging, no tracking.
How to Use
Pick a Variant
Choose Adobe Ascii85, Z85, RFC 1924, or btoa (Base64). The size stats show how much space each encoding uses.
Select Encode or Decode
Encode turns text or a file into the chosen variant; Decode turns it back into readable text.
Enter Input or Drop a File
Type, paste, or drop a text file. The output updates in real time.
Toggle Adobe Markers (optional)
For Adobe, enable '<~ ~>' delimiters to match what PDF and PostScript parsers expect.
Copy
Use the copy button to grab the encoded or decoded result.
Common Use Cases
PDF Binary Content
Encode images and fonts for embedding in PDF and PostScript using the Adobe variant.
ZeroMQ Message Payloads
Represent binary frames as Z85 text in ZMQ applications and Go services.
IPv6 Address Text
Express IPv6 addresses compactly with the RFC 1924 character set.
Size Comparison
Compare Base85's ~25% overhead against Base64's ~33% for the same input.
Compact Data Transfer
Squeeze binary into the smallest text form when bandwidth or storage matters.
Implementation Examples
// Adobe Ascii85: 4 bytes -> 5 chars (~25% overhead); 'z' = 4 zero bytesfunction adobeEncode(bytes) {const out = [];for (let i = 0; i < bytes.length; i += 4) {const chunk = bytes.slice(i, i + 4);let num = 0;for (let j = 0; j < 4; j++) num = (num * 256 + (chunk[j] || 0)) >>> 0;if (chunk.length === 4 && num === 0) { out.push('z'); continue; }const digits = [];for (let k = 0; k < 5; k++) { digits.unshift(num % 85); num = Math.floor(num / 85); }for (let k = 0; k < chunk.length + 1; k++) out.push(String.fromCharCode(digits[k] + 33));}return '<~' + out.join('') + '~>';}console.log(adobeEncode(new TextEncoder().encode('hello world')));// "<~BOu!rD]j7BEbo7~>"
Base85 variants vs Base64
| Encoding | Alphabet | Overhead | Primary Use |
|---|---|---|---|
| Adobe Ascii85 | ! to u + z | ~25% | PDF, PostScript |
| Z85 | 0-9 a-z A-Z + 23 symbols | ~25% | ZeroMQ, Go |
| RFC 1924 | 0-9 A-Z a-z + 23 symbols | ~25% | IPv6 addresses |
| btoa (Base64) | A-Z a-z 0-9 + / | ~33% | Web, email, APIs |
Production Best Practices & Security
Frequently Asked Questions
ASCII85 (also called Base85) is a binary-to-text encoding that turns 4 bytes into 5 printable characters. Because five base-85 digits can represent every 32-bit value, it only adds about 25% overhead for full blocks — the most space-efficient of the common text encodings.
By contrast, Base64 adds ~33% and hex doubles the size. The trade-off is that ASCII85 needs an 85-character alphabet and, depending on the variant, punctuation that may need escaping in source code.