$npx skillfedfor your agent

compact-json

A JSON formatter that produces compact but human-readable

With conditionsPyPI UtilitiesReleased Dec 20251.1M downloads / moMITPure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — compact_json-1.8.2-py3-none-any.whl
v1.8.2 · released 2025-12-26 · Python <4.0,>=3.9 · 3 runtime deps: wcwidth, setuptools, importlib-resources

Yes, if you need compact JSON formatting and can accept the aging maintenance status. The package is stable, has no known vulnerabilities, and works with current Python versions. However, the explicit deprecation notice and recommendation to migrate to fractured-json suggest this is a good time to evaluate whether that alternative better suits your long-term needs. Install only if you are comfortable with a package that receives infrequent updates.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires Python 3.9 or later (supports up to 3.14); package is deprecated and maintainers recommend migrating to fractured-json.
  • Low install friction with three lightweight runtime dependencies (wcwidth, setuptools, importlib-resources).
  • Maintenance status is aging—last release was 231 days ago—but the package is not archived and the repository remains active with 41 stars.

License · maintenance · safety

MIT (permissive) — MIT license permits commercial and private use with minimal restrictions; you may use, modify, and distribute the package freely provided you retain the license notice.

last release 2025-12-26 (231 days) · last repo commit 2025-12-26 · 41 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 1,069,547 downloads/mo, #4,407 on PyPI

Verify before relying

import json
from compact_json import Formatter

formatter = Formatter()
formatter.indent_spaces = 2
formatter.max_inline_complexity = 10

with open("input.json", "r") as f:
    obj = json.load(f)
    json_string = formatter.serialize(obj)
    print(json_string)
  • Whether the aging maintenance status (231 days since last release) affects stability or compatibility with recent Python patch versions.
  • Performance characteristics when formatting very large JSON files or deeply nested structures.
  • Real-world adoption and whether the deprecation notice has driven users away to fractured-json.
Same gist for agents: .md · .json

What it is and what it does

compact-json is a JSON formatter that balances readability with compactness by applying three formatting strategies: fitting simple objects and arrays onto a single line when they are short and not deeply nested, arranging complex lists across multiple lines with several items per line, or expanding each property or array item onto its own indented line. It exposes a Formatter class with configurable properties like max_inline_length, max_inline_complexity, and indent_spaces, allowing you to tune the output to your needs. It also provides a command-line utility for formatting JSON files directly from the shell.

The package is now deprecated and its maintainers explicitly recommend migrating to fractured-json, which tracks the upstream FracturedJson .NET project. Despite the deprecation notice, compact-json remains functional and receives occasional maintenance; it supports Python 3.9 through 3.14 and has no known security vulnerabilities. The three runtime dependencies are lightweight and widely available.

Use it for

  • Format API responses or configuration files to a compact but readable form for logging or debugging without the verbosity of standard pretty-printing.
  • Reduce JSON file size while keeping the output human-readable for version control or data interchange.
  • Configure formatting rules (line length, nesting depth, indentation) to match your project's style guide or readability preferences.
  • Use the command-line tool in shell pipelines to format JSON from stdin or batch-process multiple JSON files with consistent settings.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

With conditions

Yes, if you need compact JSON formatting and can accept the aging maintenance status.

The package is stable, has no known vulnerabilities, and works with current Python versions. However, the explicit deprecation notice and recommendation to migrate to fractured-json suggest this is a good time to evaluate whether that alternative better suits your long-term needs. Install only if you are comfortable with a package that receives infrequent updates.

Install

compact-json on PyPI

Before you install

Low install friction with three lightweight runtime dependencies (wcwidth, setuptools, importlib-resources). Maintenance status is aging—last release was 231 days ago—but the package is not archived and the repository remains active with 41 stars.

Requires Python 3.9 or later (supports up to 3.14); package is deprecated and maintainers recommend migrating to fractured-json.

License in practice

MIT license permits commercial and private use with minimal restrictions; you may use, modify, and distribute the package freely provided you retain the license notice.

Quickstart

import json
from compact_json import Formatter

formatter = Formatter()
formatter.indent_spaces = 2
formatter.max_inline_complexity = 10

with open("input.json", "r") as f:
    obj = json.load(f)
    json_string = formatter.serialize(obj)
    print(json_string)

Verify before relying

  • Whether the aging maintenance status (231 days since last release) affects stability or compatibility with recent Python patch versions.
  • Performance characteristics when formatting very large JSON files or deeply nested structures.
  • Real-world adoption and whether the deprecation notice has driven users away to fractured-json.

Package facts

LicenseMIT permissive
Python supportSupports the current Python release <4.0,>=3.9
Install frictionLow. Pure-Python wheel
Runtime dependencies
3 packages
wcwidthsetuptoolsimportlib-resources
MaintenanceAging 231 days since the last release
Last repo commit
First released
Downloads1,069,547 / month, #4,407 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
License :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: 3.9

Evidence: compact_json-1.8.2-py3-none-any.whl

Tags

Capabilities
json formatter compacthuman readable json outputconfigurable json formattingjson line length controlpretty print json compact
Topics
json-formattingcli-tool

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “json formatter compact”

  • compact-jsonFormats JSON into compact, human-readable output by fitting objects…
  • flake8-jsonA Flake8 plugin that formats linting output as JSON, with options for…
  • py-ubjsonEncodes and decodes data in Universal Binary JSON format, a compact…

Give your agent the search over MCP, or paste the wish link into any chat.

More Utilities packages

idna Worth it
PyPI · Python Modules · released Jun 2026

Converts domain names between Unicode and ASCII-compatible encoding (Punycode) according to IDNA 2008 and Unicode Technical Standard 46, with security validation and broader script coverage than the standard library.

Install it if you work with internationalized domain names, need to validate domains, or use HTTP clients that depend on it transitively.

BSD-3-Clausepure Python · 3.9+
1.8Bdownloads / mo
charset-normalizer Worth it
PyPI · Utilities · released Aug 2026

Detects and normalizes text encoding from unknown or ambiguous sources, supporting all IANA character sets that Python's core library provides codecs for, with the ability to register custom codecs.

permissive licensepure Python · 3.7+
1.7Bdownloads / mo
setuptools Worth it
PyPI · Python Modules · released Aug 2026

Setuptools is a Python build backend and package management tool that handles building, distributing, and installing Python packages, including support for C/C++ extension modules.

MITpure Python · 3.10+
1.6Bdownloads / mo
pluggy Worth it
PyPI · Libraries · released May 2025

Pluggy provides a plugin system that lets you define hook specifications and register implementations to be called in sequence, enabling extensible Python applications without tight coupling.

Install it if you're building an extensible application or framework.

MITpure Python · 3.9+aging
1.3Bdownloads / mo
Pygments Worth it
PyPI · Utilities · released Mar 2026

Pygments is a syntax highlighter that colorizes source code and text in over 500 languages and formats, outputting to HTML, LaTeX, RTF, SVG, images, or ANSI terminal sequences.

Install it if you need to display or transform source code.

BSD-2-Clausepure Python · 3.9+
1.3Bdownloads / mo
six With conditions
PyPI · Libraries · released Dec 2024

Six provides utility functions to write Python code that runs on both Python 2.7 and Python 3.3+, smoothing over language differences between the two versions.

MITpure Python
1.2Bdownloads / mo

See also condense-json · xmlformatter · dmiparser · objprint · perky · jsonstreams · rison · json-flatten · jsondiff