Skip to content

Menu

Properties to YAML

Convert .properties files to YAML

Runs entirely in your browserConvertersFree, no sign-up
Loading tool

01What is Properties to YAML?

Java .properties files are flat lists of key=value lines. Spring Boot, Quarkus and Micronaut also read nested YAML, which is much easier to scan once a config grows past a screen. This converter turns one into the other. It splits every key on its dots and builds a tree, so spring.datasource.url and spring.datasource.username land under a single spring: datasource: block. The parser follows the loading rules documented for Java's Properties.load method. A key ends at the first unescaped =, : or whitespace. A trailing backslash continues the line, and the next line's leading spaces are dropped. Escapes such as \=, \:, an escaped space, \n, \t, \\ and \u00e9 style Unicode sequences are decoded. Lines that start with # or ! are treated as comments. On the YAML side, keys come out sorted alphabetically. Only true, false and plain numbers like 8080 or 0.75 are written bare. Everything else stays a string, and we quote it whenever a YAML parser could misread it. That covers on, yes, 007, 1e5, JDBC URLs, passwords containing # or :, and empty values, which become "". The quoting is aimed at YAML 1.1 parsers such as SnakeYAML, the library Spring Boot uses, which treat on and yes as booleans. Here is a quick example. Paste name=Caf\u00e9, flag=on, pw=ab#c and empty= on four lines. You get empty: "", flag: "on", name: "Café" and pw: "ab#c". The Unicode escape is decoded, and every value that could be misread is protected with quotes. Comments get special handling. With Include comments in output ticked, they are gathered into one block at the top of the YAML, not kept beside the keys they described. Untick it and they are dropped. There are honest limits too. Properties lets a key hold a value and also have child keys, like db=main next to db.host=localhost. A YAML map cannot do both, so the parent's value is dropped and a # Warning line at the top tells you which key lost it. Sorting also throws away your original grouping. Profile-specific files, placeholders like ${PORT} and Spring's list syntax such as servers[0] are not interpreted. They are just treated as ordinary keys and string values. The conversion happens in the page's own JavaScript, so your config text stays in the browser tab.

Spring Boot and other JVM developers moving application.properties files to YAML, plus platform engineers packing that config into ConfigMaps or Helm values. The tool runs entirely in your browser, so your data never leaves your device.

02How to use Properties to YAML

  1. Paste your .properties content into Properties Input, or load one of the examples.
  2. Leave Include comments in output ticked to keep your comments, or untick it to drop them.
  3. Read the nested YAML Output, which updates as you type.
  4. Check the top of the output for any # Warning lines about dropped parent values.
  5. Click Copy and save the result as application.yml or your target file.

03Worked examples

Input: server.port=8080 server.ssl.enabled=true spring.application.name=demo
Result: server: port: 8080 ssl: enabled: true spring: application: name: demo
Dotted keys become nested maps, and 8080 and true are written as a number and a boolean.
Input: app.version=1.10 app.id=007 app.ratio=0.5
Result: app: id: "007" ratio: 0.5 version: "1.10"
Values that would change if read as numbers (a leading zero or a trailing zero) stay quoted strings, and keys are sorted alphabetically.
Input: db=main db.host=localhost
Result: # Warning: db had its own value (main) and child keys; YAML can't hold both, so the value was dropped db: host: localhost
Properties allows a key to have both a value and child keys, but a YAML map can't, so the parent's value is dropped and a warning is added.
Input: msg=Hello World path\ with\ space = a:b key : value
Result: key: value msg: Hello World path with space: "a:b"
Escaped spaces in a key are decoded, a colon works as a separator just like =, and a value containing a colon gets quoted.
Input: name=Caf\u00e9 flag=on pw=ab#c empty=
Result: empty: "" flag: "on" name: "Café" pw: "ab#c"
The Unicode escape is decoded, on stays a string instead of becoming true, a # inside a value is quoted, and an empty value becomes "".
Input: # db config url=jdbc:mysql://h:3306/x long=one \ two
Result: # db config long: one two url: "jdbc:mysql://h:3306/x"
With Include comments in output ticked, the comment moves to the top. The backslash continuation joins the two lines and drops the indent.

04Common use cases

  • Migrating a Spring Boot application.properties to application.yml before adding profile sections
  • Turning Kafka producer or consumer settings into YAML for a Helm values file or Kubernetes ConfigMap
  • Reviewing a 200-line flat config by viewing it grouped into nested sections
  • Moving Quarkus or Micronaut settings between formats during a framework upgrade
  • Checking whether a value like on, yes or 007 will survive the switch to YAML without changing type
  • Spotting keys that clash, where one key is both a value and the parent of other keys

05Tips

  • If a key is both a value and a parent (logging.level=INFO plus logging.level.root=DEBUG), the shorter key's value is dropped. Read the # Warning line and move that value somewhere valid.
  • Values like on or 007 come out quoted on purpose. Unquoted, a YAML 1.1 parser would read them as the boolean true and the number 7.
  • A version string like 1.10 is quoted because a number parser would turn it into 1.1.
  • Comments all move to one block at the top, so drag each one back beside the key it explains.
  • Spring list keys like servers[0] stay as literal keys here. Rewrite them as a YAML list by hand.

06Related concepts

Java properties, YAML, Spring Boot configuration, Configuration management, Key-value files.

Frequently Asked Questions

What is Properties to YAML?

Properties to YAML is a free, browser-based developer tool on AIDToolStack. Convert .properties files to YAML It requires no installation or sign-up and works entirely in your browser.

Is Properties to YAML free to use?

Yes. No sign-up, no fees and no usage cap.

Does Properties to YAML store my data?

No. It runs in your browser; nothing is uploaded.

Reviews and commentsShow

Reviews

Sign in to leave a review.

Loading reviews…

Comments

Sign in to leave a comment.

Loading comments…

What changed in AI dev tools, once a month

Renames, shutdowns, pricing changes and new MCP setups, each with a source.

Subscribe