Skip to content

XML to YAML Converter

Old XML config into readable YAML, with attributes and repeated tags handled properly.

Drop an XML file here, or click to choose one

Converted on your device — the file is never uploaded

YAML

Quick Tool Overview

The XML to YAML Converter rewrites XML as readable YAML: repeated tags become lists, attributes keep a prefix of your choosing, and empty elements become null.

What it does
Converts XML to YAML
You give it
An XML config or document
You get back
Equivalent YAML, indented as you like
Best for
Migrating old XML configuration
Converters Free, unlimited use No sign-up Runs in your browser

About the XML to YAML Converter

Plenty of systems are moving off XML configuration and onto YAML — Spring, Maven-era build tooling, CI pipelines, application settings. Doing it by hand means turning every element into a key, working out which repeated tags are lists, and deciding what to do with attributes, which YAML has no direct equivalent for.

Paste the XML and read the YAML. Elements become keys, repeated tags become lists, an element with attributes and text keeps its text under #text, and an empty element becomes null. Attributes can carry an @ or _ prefix, or be merged in as plain keys. Numbers and true/false can be read as real types rather than strings, and the root element can be kept as the top-level key or dropped. Everything runs in your browser, so internal config never leaves your machine.

Key features of the XML to YAML Converter

Lists from repeated tags

Two or more siblings of the same name become a YAML list.

Attribute prefix

@, _ or none, so attributes never collide with child elements.

Mixed content kept

Text alongside child elements is preserved under a #text key.

Real types

Numbers and true/false can be read as types instead of strings.

Root optional

Keep the root element as the top-level key, or drop it.

How to use the XML to YAML Converter

  1. 1

    Paste or drop the XML

    Any well-formed document; a parse error names the line it gave up on.

  2. 2

    Choose how attributes are written

    @ keeps them distinct, _ suits some loaders, plain merges them in.

  3. 3

    Set types and the root

    Read numbers and booleans as real types, and keep or drop the root element.

  4. 4

    Copy or download the YAML

    Paste it into your config, manifest or pipeline file.

Frequently asked questions

Two or more sibling elements with the same name become a YAML list. A single element stays a plain key, since there is no way to tell from one occurrence that a list was intended.

Reviews of the XML to YAML Converter

What people who use the XML to YAML Converter think of it. Reviews come from visitors and are posted as written.

No ratings yet

Yours would be the first.

  • 5 0 reviews rated 5 stars
  • 4 0 reviews rated 4 stars
  • 3 0 reviews rated 3 stars
  • 2 0 reviews rated 2 stars
  • 1 0 reviews rated 1 star

Write a review

Used this tool? Your rating helps the next person decide.

Your rating

Plain text only — links, email addresses and HTML are not accepted. Your name and review are shown publicly; nothing else is collected. See the privacy policy.

0 reviews

Newest first

No reviews yet

Be the first to rate the XML to YAML Converter. It takes half a minute and no account.

Write the first review

More converters