Binary Data in XML

Andrew Layman andrewl at
Wed Sep 30 19:25:01 BST 1998

Tim Bray wrote

"Base64 (a 4-for-3 encoding) wastes 33%, so I thought about perhaps
inventing Base128 (8-for-7) or maybe even a higher level to cut down
wasteage, but Base64 has the advantage that it avoids UTF8/ISO-8859 
confusion and I bet Mr. LZW will eat that 33% anyhow..."

The thing to consider here is that, although XML is Unicode, the typical
encoding of it is predominantly ANSI octets, in which case Base64 works
pretty well.  But run some tests...

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev at
Archived as:
To (un)subscribe, mailto:majordomo at the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo at the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa at

More information about the Xml-dev mailing list