--- id: tomlkit version: "0.15.1" license: MIT license_treatment: permissive maintenance: active --- # tomlkit — Style preserving TOML library License: permissive · Maintenance: active · Popularity: top 1,000 on PyPI ## Install pip install tomlkit uv add tomlkit poetry add tomlkit ## Description [github_release]: https://img.shields.io/github/release/sdispater/tomlkit.svg?logo=github&logoColor=white [pypi_version]: https://img.shields.io/pypi/v/tomlkit.svg?logo=python&logoColor=white [python_versions]: https://img.shields.io/pypi/pyversions/tomlkit.svg?logo=python&logoColor=white [github_license]: https://img.shields.io/github/license/sdispater/tomlkit.svg?logo=github&logoColor=white [github_action]: https://github.com/sdispater/tomlkit/actions/workflows/tests.yml/badge.svg [![GitHub Release][github_release]](https://github.com/sdispater/tomlkit/releases/) [![PyPI Version][pypi_version]](https://pypi.org/project/tomlkit/) [![Python Versions][python_versions]](https://pypi.org/project/tomlkit/) [![License][github_license]](https://github.com/sdispater/tomlkit/blob/master/LICENSE)
[![Tests][github_action]](https://github.com/sdispater/tomlkit/actions/workflows/tests.yml) # TOML Kit - Style-preserving TOML library for Python TOML Kit is a **1.1.0-compliant** [TOML](https://toml.io/) library. It includes a parser that preserves all comments, indentations, whitespace and internal element ordering, and makes them accessible and editable via an intuitive API. You... ## AI interpretation — verify before relying tomlkit parses and edits TOML 1.1.0 files while preserving comments, whitespace, indentation, and element order, then serializes them back with formatting intact. Verdict: tomlkit is a well-maintained, dependency-free TOML library ideal for applications that need to read and modify TOML files without losing formatting. No known vulnerabilities, permissive MIT license, and broad Python version support make it a safe, production-ready choice. [View on SkillFed](https://skillfed.io/packages/tomlkit) · [View on PyPI](https://pypi.org/project/tomlkit/)