Base85 Encoder

Encoders & Decoders

How to use the Base85 Encoder

Encode text to Base85 in three steps:

1

Paste your text

Paste any plain text into the input area.

2

Choose variant

Select Ascii85 (with <~ ~> delimiters, PDF-compatible, z-abbreviation for null groups) or RFC 1924 Base85 (used in some network protocols).

3

Copy the encoded output

The Base85 string appears with the selected delimiters. Copy or download. The footer shows size overhead compared to Base64.


When to use this tool

Use Base85 when you need more compact binary-to-text encoding than Base64:

  • Encoding binary data for embedding in PostScript or PDF documents where Ascii85 is the native encoding format
  • Compressing data URI size by using Base85 instead of Base64 where the receiving system supports it
  • Encoding data in Python's binascii module or zlib compressed output which uses Base85
  • Encoding IPv6 addresses using the RFC 1924 Base85 variant for compact representation in protocols
  • Academic and research contexts exploring binary-to-text encoding efficiency and alphabet design
  • Encoding binary payloads for systems that require ASCII-safe encoding but where the 33% Base64 overhead is unacceptable

Frequently asked questions

Q:What is Base85 / Ascii85 and how does it work?
Base85 (Ascii85) is a binary-to-text encoding that represents every 4 bytes of binary data as 5 printable ASCII characters, using characters from ASCII 33 (!) to 117 (u) — 85 printable characters total. The encoding works by treating each 4-byte group as a 32-bit integer and expressing it in base 85. This produces approximately 25% overhead vs the original data, compared to Base64's 33% overhead.
Q:What are the <~ and ~> delimiters in Ascii85?
The <~ and ~> delimiters mark the beginning and end of an Ascii85-encoded stream, as defined in the PostScript and PDF specifications. They allow decoders to identify the encoded section within a larger document. Some implementations include these delimiters (PDF Ascii85 streams require them); others omit them. Toggle the 'Include delimiters' option based on whether the target system expects them.
Q:What is the z abbreviation in Ascii85?
In Ascii85, a group of 4 null bytes (0x00000000) is abbreviated to a single z character instead of the 5-character representation !!!!! This is a special case optimisation. When z-compression is enabled (the default), runs of null bytes in the input produce significantly shorter output. The RFC 1924 variant does not use z-abbreviation.
Q:What is the difference between Ascii85 and RFC 1924 Base85?
Ascii85 uses printable ASCII characters 33–117 (! through u) as its alphabet. RFC 1924 Base85 uses a different alphabet: 0–9, A–Z, a–z, and the symbols !#$%&()*+-;<=>?@^_`{|}~. RFC 1924 was proposed for compact IPv6 address representation. Python's base64.b85encode() uses a variant similar to RFC 1924. The encoded values differ completely between the two variants despite the same encoding principle.
Q:Where is Base85 used in practice?
Ascii85 (Base85) is used in: Adobe PostScript and PDF files (for encoding binary image and font data streams), Git binary patches (git diff --binary uses Base85 for binary file diffs), Python's binascii.b2a_base85() function, and ZeroMQ's Z85 encoding for binary frames. Base64 is far more common overall, but Base85 appears in these specific contexts where its compactness is valued.
Q:Is Base85 more secure than Base64?
No — neither Base85 nor Base64 provides any security. Both are encoding schemes that transform data representation without any encryption or obfuscation. Base85 is merely more space-efficient. For actual security, use proper cryptographic algorithms (AES for encryption, SHA-256 for hashing). Base85 vs Base64 is purely an engineering choice about size efficiency, not security.