TOML Validator
Validate TOML syntax: structure, comments, key/value errors and duplicate keys.
- Runs locally in your browser
- No upload required
Try it
Supported formats
Privacy
Runs entirely in your browser. Your input is never uploaded, stored, or sent to a third party.
Valid TOML: 1 table(s), 2 key(s).
How it works
- Scanned line by line, ignoring `#` comments and blank lines.
- Recognised table headers, key/value pairs and multi-line strings.
- Tracked duplicate keys and unterminated strings, arrays or inline tables.
- This is a pragmatic structural validator, not a full TOML parser: it reports the common syntax and structure errors and their location.
- Values are not type-checked against their TOML types beyond basic quoting; it is a syntax check, not a schema check.
Methodology
- Strip comments with quote awareness.
- Track multi-line strings, tables and inline/array nesting.
- Detect duplicate keys and report unterminated constructs with their starting line.
Usage
- Paste TOML content.
- Read the errors with their line and column.
- Fix and re-validate until the file is valid.
Examples
These are examples, not current values: they use fixed inputs, while the interactive tool computes live results in your browser.
Valid document
{
"content": "title = \"Example\"\n[server]\nport = 8080"
}Duplicate key
{
"content": "name = \"a\"\nname = \"b\""
}Unterminated string
{
"content": "name = \"unterminated"
}Limitations
What TOML is used for
TOML is a minimal configuration format used by Rust's Cargo, Python's pyproject and many build tools. It is line-oriented, so a single bad key or an unterminated string invalidates the whole file.
This validator reports the location of those faults so you can fix them quickly. It is a syntax check; run the consuming tool to enforce the schema your project expects.
Frequently asked questions
- Is this a full TOML parser?
- No. It is a structural syntax validator that catches the common errors and points at their line and column; for strict conformance use a reference parser in your build.
- Does it check value types?
- Only lightly. It verifies quoting and structure, not that a value matches an expected integer, date or enum.
Sources
Send feedback
Tell us if this tool helped, report a problem, or suggest a tool. Only the message you type is sent — never the input you used in the tool.
Was this tool useful?
Prefer to write to us directly? See the contact page.