TOML 1.0 + 1.1 · Rust

TOMLSMITH

Check and format TOML.

Use TomlSmith from Rust, the command line, an editor, or the browser. Each interface supports explicit TOML 1.0 and 1.1 modes.

TomlSmith icon: a white anvil with an orange equals sign on a navy square
TOML 1.0 · TOML 1.1 · MIT license
1,360 / 1,360
toml-test decoder cases pass for TOML 1.0 and 1.1
2 modes
published TOML 1.0 and 1.1 specifications implemented separately
3 commands
check · fmt · parse
4 surfaces
Rust library · CLI · language server · browser playground

01 — Measured performance

TOML 1.0 format and check, compared

Direct-CLI cold-start medians; package-manager launchers and wrapper processes are excluded. See TOML 1.1 and all four lanes.

Format · TOML 1.0

median latency · lower is better
TomlSmith native CLI
8.35 ms
tomll · go-toml*
10.91 ms
dprint + TOML
20.12 ms
Taplo CLI
22.07 ms

Check · TOML 1.0

median latency · lower is better
TomlSmith native CLI
10.21 ms
tomlv · BurntSushi
12.07 ms
Taplo CLI
23.34 ms
Tombi
206.80 ms

* tomll does not preserve comments or literal styles.

02 — Features

What TomlSmith does

Choose TOML 1.0 or 1.1, then run check, fmt, or parse.

01 · Versions

Explicit version modes

Choose TOML 1.0 or 1.1 for each invocation. Use --toml-version 1.0 for files read by Cargo or other 1.0-only tools.

02 · Check

Check documents

check reports errors and warnings with source ranges and diagnostic codes.

03 · Formatting

Formatting with safeguards

Formatting preserves comments and literal spellings in covered cases. Documents with parse or semantic errors are not rewritten, and fmt --check checks files without changing them.

04 · Automation

Read JSON output

parse emits the selected version, validity, and diagnostics as JSON for scripts and tools.

05 · Rust

Use the Rust API

Parse once with Document, then query diagnostics, formatted output, highlights, and decoded values.

06 · Editors

Use an editor or browser

Connect an LSP-capable editor, use the VS Code client, or run the browser playground.

03 — Projects

Project repositories

TomlSmith is split across five repositories. Each repository has a separate role.

Try TomlSmith

Follow the quick start, or use the browser Playground without installing anything.