#encoding #toml #no-std

no-std toml_parser

Yet another format-preserving TOML parser

10 stable releases

new 1.0.9+spec-1.1.0 Feb 16, 2026
1.0.8+spec-1.1.0 Feb 12, 2026
1.0.6+spec-1.1.0 Dec 18, 2025
1.0.4 Oct 9, 2025
1.0.1 Jul 11, 2025

#297 in Parser implementations

Download history 2055463/week @ 2025-11-03 2128369/week @ 2025-11-10 2342710/week @ 2025-11-17 1882706/week @ 2025-11-24 2189642/week @ 2025-12-01 2458895/week @ 2025-12-08 2559361/week @ 2025-12-15 1570136/week @ 2025-12-22 1549977/week @ 2025-12-29 2669259/week @ 2026-01-05 3013399/week @ 2026-01-12 3224546/week @ 2026-01-19 3276835/week @ 2026-01-26 3560922/week @ 2026-02-02 3861256/week @ 2026-02-09 4024586/week @ 2026-02-16

14,966,327 downloads per month
Used in 12,071 crates (12 directly)

MIT/Apache

220KB
6.5K SLoC

TOML lexer and parser

Characteristics:

  • Error recovery
  • Lazy validation
  • forbid(unsafe) by default, requiring the unsafe feature otherwise
  • no_std support, including putting users in charge of allocation choices (including not allocating)

Full parsing is broken into three phases:

  1. [Lexing tokens][lexer]
  2. [Parsing tokens][parser] (push parser)
  3. Organizing the physical layout into the logical layout, including [decoding keys and values][decoder]

toml_parser

Documentation License Crates Status

Zero-copy parsing of TOML

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Dependencies

~0.8–2.9MB
~62K SLoC