skillfed

pytoml

A parser for TOML-0.4.0

pytoml v0.1.21 604.6K downloads/30d#5,803 on PyPI132
Permissive license MIT Active released

What it is and what it does

pytoml is a TOML file parser and serializer that mirrors the standard library's json module interface. It reads TOML configuration files into Python dictionaries and writes dictionaries back to TOML format. The library accepts both bytes (UTF-8 decoded) and unicode strings as input, making it straightforward to integrate into configuration-loading workflows.

The package is deprecated and no longer maintained. Its last release was in 2019, and the project's own documentation recommends using alternatives. While it remains functional for TOML 0.4.0 files and has no known vulnerabilities, new projects should consider more actively maintained options.

Use it for:

  • Loading application configuration from TOML files in legacy projects still using this library
  • Reading TOML-formatted settings in Python 2.7 or early Python 3 codebases where migration is not yet planned
  • Parsing TOML 0.4.0 files in environments where dependency updates are constrained

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Parses and writes TOML configuration files with a JSON-like interface, supporting TOML version 0.4.0.

No, unless you are maintaining legacy code already using pytoml. The project is explicitly deprecated and unmaintained since 2019. For new projects, use an actively maintained TOML parser instead. The package itself is stable and has no known vulnerabilities, but the lack of maintenance means no fixes for future TOML spec changes or Python compatibility issues.

Install

pytoml on PyPI

pip

pip install pytoml

uv

uv add pytoml

poetry

poetry add pytoml

Installing pytoml

Before you install

Low install friction with no runtime dependencies. However, the project is no longer actively maintained—the last release was in 2019, and the maintainer explicitly recommends considering alternatives.

License in practice

MIT license permits commercial and private use with minimal restrictions, requiring only attribution and inclusion of the license notice.

Quickstart

pip install pytoml

import pytoml as toml
obj = toml.loads('a = 1')
print(obj)

with open('file.toml', 'rb') as fin:
    obj = toml.load(fin)

Requires Python 2.7+ or 3.5+; input bytes must be UTF-8 encoded with no BOM.

Verify before relying

  • Whether TOML 0.4.0 support is sufficient for current use cases or if newer TOML spec versions are needed
  • How the package compares in correctness or performance to actively maintained alternatives

Package facts

License MIT (permissive)
Python support not specified
Install friction low — pure-Python wheel
Runtime dependencies none
Maintenance actively maintained — 2,581 days since the last release
Last repo commit
First released
Downloads 604,635/month — #5,803 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: pytoml-0.1.21-py2.py3-none-any.whl

License :: OSI Approved :: MIT LicenseProgramming Language :: Python :: 2Programming Language :: Python :: 2.7Programming Language :: Python :: 3Programming Language :: Python :: 3.5Programming Language :: Python :: 3.6Programming Language :: Python :: 3.7Topic :: Software Development :: Libraries

Tags

toml parser pythontoml file readertoml configuration parsingtoml serializationparse toml files
deprecatedconfig-parsing

More Libraries packages