free · no sign-up · lossless

Convert JSON to TOON and cut
LLM tokens by 30–60%

TOON (Token-Oriented Object Notation) is a compact serialization format built for LLM prompts. Lower your GPT and Claude API costs with fast, lossless, bidirectional json ↔ toon conversion.

user@jsontotoon: ~/convert
$ jsontotoon convert --in users.json --out users.toon
 parsed 3 records · json 156 tokens
 wrote users.toon · toon 68 tokens (-56%)

# users.toon
users[3]:
  id: 1, 2, 3
  name: Alice Johnson, Bob Smith, Carol Davis
  role: admin, user, user
  • 30–60%fewer tokens
  • <1sconversion
  • 100%lossless
  • $0to use

$ converter

# see the token savings

The same user list in JSON and in TOON. TOON writes each key once and lays values out in a compact table — 56% smaller.

users.json 156 tokens
{
  "users": [
    {
      "id": 1,
      "name": "Alice Johnson",
      "email": "alice@example.com",
      "role": "admin"
    },
    {
      "id": 2,
      "name": "Bob Smith",
      "email": "bob@example.com",
      "role": "user"
    },
    {
      "id": 3,
      "name": "Carol Davis",
      "email": "carol@example.com",
      "role": "user"
    }
  ]
}
users.toon 68 tokens · -56%
# 56% fewer tokens, same data
users[3]:
  id: 1, 2, 3
  name: Alice Johnson, Bob Smith, Carol Davis
  email: alice@example.com, bob@example.com, carol@example.com
  role: admin, user, user

# json vs toon

featurejsontoon
token efficiencyhigh redundancy30–60% reduction
human readabilitygoodexcellent
api cost savingsstandard costssignificant savings
llm compatibilityuniversalgpt, claude, gemini
repeated keysevery objectonly once
array syntaxverbose bracketscompact tabular

# why convert json to toon

reduce_llm_tokens()

TOON serialization eliminates redundant JSON syntax — brackets, braces, and repeated keys — cutting tokens by up to 60%.

💸

lower_api_costs()

Reduce GPT token costs and Claude API costs. Fewer tokens per prompt means a smaller bill for structured payloads.

🆓

completely_free()

No account, no credit card, no limits. Convert unlimited JSON to TOON anytime in your browser.

🔒

private_by_default()

No sign-up and no tracking. Conversions hit a stateless HTTPS endpoint, are processed in memory, and never stored or logged.

🚀

instant_convert()

Convert JSON to TOON in well under a second, with immediate token-savings feedback.

🔁

bidirectional()

Convert JSON to TOON for prompts, then back to JSON when needed — round-trips preserve every value.

# how to convert json to toon

  1. 01

    paste your json

    Copy your JSON and paste it into the input pane. The converter supports all standard JSON.

  2. 02

    choose a direction

    Use json → toon to compress for LLM prompts, or toon → json to convert back.

  3. 03

    convert instantly

    Hit convert and watch your data transform into compact TOON with a live token-reduction estimate.

  4. 04

    copy your output

    Click copy and drop the TOON straight into your GPT, Claude, or Gemini prompt.

# about toon format

TOON (Token-Oriented Object Notation) is a compact format designed for LLM inputs. It achieves up to 60% fewer tokens than JSON while staying lossless and deterministic.

  • YAML-style indentation for nested structures
  • CSV-like tabular layouts for uniform arrays
  • Explicit array length declarations
  • Reduced quoting requirements

Official implementations exist for TypeScript/JavaScript, Python, Rust, and Java. Install with npm install toon-format, or use our REST API. Source: github.com/toon-format/toon.

# faq

What is TOON serialization format?

TOON (Token-Oriented Object Notation) is a compact data format designed for LLM inputs. It combines YAML-style indentation with CSV-like tabular layouts to eliminate the redundant brackets, braces, and repeated keys found in JSON, reducing token count by 30–60% while remaining lossless.

JSON vs TOON: which format is better for LLMs?

Both are readable and lossless, but TOON uses far fewer tokens for uniform arrays of objects because it writes each key only once and lays the values out in a compact tabular form. For data sent to LLMs where token cost matters, TOON is typically the better choice.

How does TOON format reduce API costs?

LLM APIs bill per token. Because TOON removes repeated keys and structural punctuation, the same data uses 30–60% fewer tokens, which directly lowers the cost of every prompt that contains structured data.

Can TOON optimize GPT token usage?

Yes. TOON reduces the number of tokens GPT models need to read for the same payload, lowering input token usage and cost without losing any data.

How much token reduction can I actually expect?

Typical reductions are 30–60%. Savings are highest for uniform arrays of objects (tabular data) and lower for deeply nested or highly irregular structures.

Do you support converting TOON back to JSON?

Yes. Conversion is fully bidirectional and lossless — JSON → TOON → JSON returns identical data. Use the toon → json toggle in the converter.

Is my data safe? Where does it go?

We require no account and store none of your conversions. Data is sent over HTTPS to a stateless conversion endpoint, processed in memory, and never logged or retained.

Does TOON work for all types of JSON?

TOON handles any valid JSON. Token savings are largest for uniform arrays of objects; nested or irregular data still converts losslessly but with smaller reductions.

Do I need to install anything or sign up?

No. The web converter is free and needs no account. For programmatic access there is also a REST API and an official toon-format library for TypeScript, Python, Rust, and Java.

Can LLMs like GPT and Claude understand TOON format?

Yes. TOON is plain text with a simple, regular structure that GPT, Claude, and Gemini parse reliably. Including a short format description in your prompt makes results even more consistent.

~/get-started

$ start cutting your llm token costs

Convert JSON to TOON for free in your browser, or grab an API key for programmatic access.