Convertor PRO — Examples

Concrete runs with Convertor PRO: JSON to YAML, YAML to TOML, text to hex and Unicode, decoding HTML entities, making XML readable.

Back to the overview: Convertor PRO · Open the live tool: www.jpkc.com/tools/convertor/

The Manual describes every field and mode in detail. This page adds concrete runs: typical tasks, step by step, focused on what you enter and what comes out. The tool's interface is in English, so tab and button names are given as they appear in the UI.

Example 1: JSON to YAML

You have a compact JSON config and want it as readable YAML — say for a CI pipeline or a docker-compose-style file.

  1. Open Convertor PRO and switch to the Data Formats tab.
  2. Set Source to JSON, Output to YAML.
  3. Paste your JSON on the left, e.g.:
{ "service": "web", "port": 8080, "tags": ["a", "b"], "debug": true }
  1. Click Convert. On the right you get:
service: web
port: 8080
tags:
  - a
  - b
debug: true

YAML writes strings without quotes, numbers and booleans stay typed, and arrays become lists. Use Copy to grab the result, or Save to download it as a .yaml file.

Example 2: YAML to TOML

Same family, opposite direction: you want a YAML config as TOML, e.g. for a Rust or Python tool that expects pyproject.toml-style files.

  1. In the Data Formats tab: Source to YAML, Output to TOML.
  2. If the output from Example 1 is still on the right, just click Swap — the YAML output slides left and becomes the new input.
  3. Otherwise paste your YAML:
title: My Project
owner:
  name: Jane
  active: true
  1. Convert produces:
title = "My Project"

[owner]
name = "Jane"
active = true

Nested objects become [table] blocks. Note that comments from the YAML do not carry over — the conversion runs through a pure data intermediate stage (see Limits and edge cases).

Example 3: Text to hex and Unicode

You're embedding an emoji or a special letter into HTML, CSS, or a JavaScript string and need the correct escape notation.

  1. Switch to the Encoding tab.
  2. Type the character into the Characters field, e.g. 😀 or café.
  3. Click the Convert button right next to Characters.
  4. All other fields fill in at once. For 😀 you can read off, e.g.:
    • Hexadecimal NCRs: 😀 (for HTML/XML)
    • Unicode U+hex: U+1F600
    • UTF-8 code units: the UTF-8 byte sequence
    • CSS escapes and JavaScript escapes: the notation valid for CSS and JS strings respectively
  5. Use the copy button next to the relevant field to grab exactly the notation you need.

Tip: if you only want to escape the special characters and keep ASCII letters readable, leave the ASCII checkbox on (the default) — then cafe stays as is and only the é is converted.

Example 4: Decoding HTML entities

You have text from some source containing entities like &, ü, or —, and you want the plain text.

  1. Encoding tab.
  2. Paste the text into the HTML/XML field, e.g. R&D über alles — good.
  3. Click the Convert button at HTML/XML.
  4. The Characters field now holds the plain text: R&D über alles — good. The field understands named entities (&, ü, …) as well as numeric ones (—).

For wildly mixed escapes from several notations at once, use the Mixed input field and its Convert button instead — it resolves different escape kinds in one go.

Example 5: XML readable as JSON

An API returned XML and you want to grasp the structure quickly as JSON.

  1. Data Formats tab. Paste the XML with Paste — detection recognizes the leading < and sets Source to XML automatically.
  2. Set Output to JSON and click Convert. From
<book id="42"><title>Faust</title><year>1808</year></book>

you get

{
  "@id": "42",
  "title": "Faust",
  "year": 1808
}
  1. Note the conventions: attributes get an @ prefix (@id), and text-only values are auto-typed where possible (1808 becomes a number). Repeated same-named elements would become an array. Note also: the name of the root element (book) is lost in the XML→object step — the mirror image of the "object → XML" direction, where the tool conversely has to invent a root name.

Example 6: INI to JSON — and why not every road leads back

INI is handy for reading legacy configurations.

  1. Data Formats tab. Source to INI, Output to JSON. Input:
debug = true
[database]
host = localhost
port = 5432
  1. Convert produces nested JSON with debug at the root and a database object. Unquoted values are auto-typed: true becomes a boolean, 5432 a number.
  2. The reverse hits INI's limit: deeply nested objects are flattened with dot notation when written to INI, and an array at the root level cannot be emitted as INI at all — then the tool reports that INI needs an object at the top. For richly structured data, JSON, YAML, or TOML is the better target.

More tricks — low-loss round-trips, using detection deliberately, combining with other tools — are in Tips & Tricks.