Convert TONL to XML with our free online converter.
Use the converter below or open in full converter with more options.
The output below was generated by the same conversion code the converter uses, run on this sample when the page was built.
#version 1.0
root:
log:
events[4]{latencyMs,level,service,ts}:
42,info,auth,"2026-09-30T08:12:04Z"
310,warn,billing,"2026-09-30T08:12:09Z"
38,info,auth,"2026-09-30T08:12:15Z"
1204,error,search,"2026-09-30T08:12:21Z"<log>
<events>
<latencyMs>42</latencyMs>
<level>info</level>
<service>auth</service>
<ts>2026-09-30T08:12:04Z</ts>
</events>
<events>
<latencyMs>310</latencyMs>
<level>warn</level>
<service>billing</service>
<ts>2026-09-30T08:12:09Z</ts>
</events>
<events>
<latencyMs>38</latencyMs>
<level>info</level>
<service>auth</service>
<ts>2026-09-30T08:12:15Z</ts>
</events>
<events>
<latencyMs>1204</latencyMs>
<level>error</level>
<service>search</service>
<ts>2026-09-30T08:12:21Z</ts>
</events>
</log>XML output is 136% larger than the TONL input. The same data is 337 characters as minified JSON and 572 as pretty-printed JSON. Sizes are character counts, not tokens: token counts depend on the model's tokenizer (see the tokenizer comparison).
TONL (Token-Optimized Notation Language) is a compact text format that maps one-to-one to JSON and ships with a query API, schema validation, and streaming. Savings are roughly 32-45% versus JSON in the TONL project's own measurements.
Extensible Markup Language is a verbose but powerful format. Still widely used in legacy systems, SOAP APIs, and document formats.
Use XML when working with legacy systems, SOAP APIs, or when you need rich metadata and validation schemas.
Paste your TONL into the editor on json2toon.co. The tool detects the input and produces XML instantly, then you copy the result. Conversion runs entirely in your browser, so nothing is uploaded to a server.
Yes. Converting TONL to XML on json2toon.co is free with no account, signup, or usage limit. A free public API is also available for automated, programmatic conversion.
Convert TONL to XML with our free online converter.
XML needs exactly one root element. Several top-level keys, or a top-level key holding an array, produce sibling roots that are not well-formed XML, which is why this sample is wrapped in a single key. Keys prefixed with @_ become attributes.
Yes. The TONL to XML conversion happens client-side in your browser. Your source data stays on your device and is never sent to or stored on a server, which makes it safe for private or sensitive payloads.