Skip to content

TOML validator

Checks whether the TOML parses. The text in the editor is not rewritten.

Ctrl+Enter or ⌘+Enter runs this tool immediately.

TOML to check

Waiting for input.

Parsing stays in this browser. Input is not uploaded or saved.

How to use this tool

  1. Paste TOML, or load the sample.
  2. Read the validation panel. A successful check describes the top-level shape and does not pretty-print the text.
  3. Copy the input from the editor if you want the original bytes.

Supported formats and limitations

  • Supported syntax is TOML 1.1 as implemented by smol-toml.
  • inf and nan are rejected. Integers outside ±(2^53 − 1) are rejected.
  • The check does not format, sort, or repair the document.
  • Keys named __proto__ or constructor are rejected.
  • A successful result leaves the editor text unchanged.

Examples

A table

A table is valid when every key has a value.

[server]
host = "localhost"
port = 8080

A missing value

A bare key with no equals sign is a syntax error.

port

Common errors and solutions

Invalid TOML document
Use the reported line and column. A missing value after = is a common cause.
Non-finite number
Replace inf or nan with a finite number or a quoted string.
Integer outside the safe range
Quote the integer if you need every digit. The validator will not round it.

FAQ

Does a successful check reformat the file?
No. The editor keeps the text you pasted, including spacing and comments.
Which TOML version is checked?
The parser is smol-toml, which targets TOML 1.1.0.
Is the document sent anywhere to be checked?
No. Validation runs in your browser on the text in the editor.

Related tools

  • TOML to JSON converter

    Convert TOML 1.1 configuration to JSON in the browser, including tables, arrays, strings, booleans, dates, and numbers, with explicit notes where the types differ.

  • TOML to YAML converter

    Convert TOML 1.1 configuration to YAML with 2-space or 4-space indentation. Dates become strings, comments are dropped, and invalid TOML produces no YAML.

  • YAML validator

    Check YAML syntax without converting or rewriting it. Errors include a line and column when the parser provides them, and valid input is left unchanged.