User Rating 0.0
Total Usage 0 times
Drop .bxml file here or click to browse Supports files up to 100 MB
Is this tool helpful?

Your feedback helps us improve.

About

BXML (Binary XML) is a compact binary encoding of XML documents used in game engines, embedded systems, and data-interchange pipelines where parsing speed and file size matter more than human readability. The format replaces verbose tag names and attribute keys with integer indices into a string table, strips whitespace, and packs values into typed binary fields. Without a decoder, BXML files are opaque byte streams. This tool reconstructs the original XML document tree from the binary representation, restoring tag names from the string table, re-serializing attributes, and producing properly indented, valid XML output. All processing occurs client-side in your browser - no data is transmitted to any server.

The parser handles multiple BXML variants by inspecting magic bytes and header structure. It supports string-table-indexed tags, inline UTF-8 text nodes, nested element hierarchies, and CDATA sections. Limitations: proprietary BXML schemas with encryption or custom compression layers (e.g., LZ4-wrapped payloads) are not supported without prior decompression. The reconstructed XML preserves document structure but not original whitespace or comment placement, as these are typically discarded during binary encoding. For files exceeding 5 MB, processing is offloaded to a background thread to keep the interface responsive.

bxml xml binary xml converter file converter xml parser bxml decoder

Formulas

BXML decoding follows a deterministic binary read sequence. The file begins with a header, followed by a string table, then a recursive node tree.

Header magic (4 bytes) + version (2 bytes) + stringTableOffset (4 bytes) + stringTableSize (4 bytes) + nodeTreeOffset (4 bytes)

StringTable count (4 bytes) + [ offseti (4 bytes) ]i=0..count + UTF-8 blob

Node type (1 byte) + nameIdx (4 bytes) + attrCount (2 bytes) + [ Attr ]attrCount + childCount (4 bytes) + [ Node ]childCount

Attr keyIdx (4 bytes) + valueType (1 byte) + value (variable)

Where nameIdx and keyIdx are zero-based indices into the string table. valueType determines how the value field is read: 0x01 = string index (4 bytes), 0x02 = int32 (4 bytes), 0x03 = float32 (4 bytes), 0x04 = boolean (1 byte). Node type 0x01 = element, 0x02 = text, 0x03 = CDATA. The reconstructed XML indentation depth d produces d × indentSize leading spaces per line.

Reference Data

FeatureBXML (Binary XML)XML (Text)
EncodingBinary (typed fields)UTF-8 / UTF-16 text
Human ReadableNoYes
Typical Size Ratio0.3× - 0.6× of XML1.0× (baseline)
Parse SpeedFast (no tokenization)Slower (requires lexer)
String StorageIndexed string tableInline repetition
Attribute ValuesTyped (int, float, bool, string index)Always string
WhitespaceStrippedPreserved
CommentsUsually discardedPreserved
CDATA SectionsFlagged by type byteDelimited by <![CDATA[
Namespace SupportVia string table prefixNative xmlns
Common Magic Bytes0x42 0x58 0x4D 0x4C ("BXML")<?xml
Schema ValidationNot embeddedDTD / XSD references
Typical Use CasesGame assets, IoT configs, cachesWeb services, configs, documents
Streaming ParseYes (sequential reads)SAX / StAX
CompressionInherent (compact encoding)Requires gzip / brotli
Max Nesting DepthLimited by stack / specUnlimited (spec)
EndiannessLittle-endian (typical)N/A
Boolean Encoding0x00 / 0x01true / false
Float EncodingIEEE 754 (4 or 8 bytes)Decimal string
Integer EncodingFixed-width or varintDecimal string
File Extension.bxml, .bin.xml

Frequently Asked Questions

The converter supports the common BXML format with magic bytes 0x42 0x58 0x4D 0x4C ("BXML"), which uses a string-table-indexed structure with typed attribute values. It also handles headerless variants by attempting heuristic detection of the string table. Proprietary encrypted or LZ4/zlib-compressed BXML files must be decompressed before conversion.
No. All parsing and XML reconstruction occur entirely within your browser using the FileReader and ArrayBuffer APIs. The file never leaves your device. You can verify this by disconnecting from the internet before converting - the tool works fully offline.
This typically occurs when the file uses a proprietary BXML schema with non-standard type bytes or a different endianness than little-endian. The converter expects standard type codes: 0x01 (element), 0x02 (text), 0x03 (CDATA) for nodes, and 0x01-0x04 for attribute value types. If your file uses a custom mapping, the string table lookups will resolve to incorrect names. Check the hex dump of your file's first 20 bytes to verify the header structure matches the expected format.
The converter handles files up to approximately 100 MB in modern browsers. Files exceeding 5 MB are automatically processed in a Web Worker to prevent UI freezing. Actual limits depend on available device memory, as the entire ArrayBuffer must fit in RAM alongside the reconstructed XML string. For very large files (>50 MB), ensure your device has at least 500 MB of free memory.
Yes. The tool includes a hex input mode where you can paste space-separated or continuous hexadecimal bytes (e.g., "42 58 4D 4C 01 00..." or "42584D4C0100..."). The converter parses the hex string into an ArrayBuffer and processes it identically to a file upload. This is useful for debugging or when working with hex dumps from network captures.
Namespaces in BXML are stored as prefixed strings in the string table (e.g., "ns:tagName"). The converter preserves these prefixes in the output XML. However, it does not automatically reconstruct xmlns declarations in the root element, as these are typically not stored in BXML. You may need to manually add xmlns attributes to the root element if your downstream XML parser requires them.