$npx skillfedfor your agent

JSON-log-formatter

JSON log formatter

Worth itPyPI Python ModulesReleased Jun 20263.1M downloads / moMITPure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — json_log_formatter-1.2.1-py3-none-any.whl
v1.2.1 · released 2026-06-08 · Python >=3.9

Yes. The package is lightweight, dependency-free, actively maintained, and solves a concrete problem—structured JSON logging is now standard practice for production systems. Install it if you're already using Python's logging module and need JSON output for log aggregation or cloud platforms.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires Python 3.9 or later.
  • Low install friction—pure Python wheel with no runtime dependencies.
  • Actively maintained as of June 2026 with recent release history.

License · maintenance · safety

MIT (permissive) — MIT license permits unrestricted use, modification, and distribution in commercial and private projects.

last release 2026-06-08 (67 days) · last repo commit 2026-06-08 · 118 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 3,134,411 downloads/mo, #2,734 on PyPI

Verify before relying

import logging
import json_log_formatter

formatter = json_log_formatter.JSONFormatter()
json_handler = logging.FileHandler(filename='/var/log/my-log.json')
json_handler.setFormatter(formatter)

logger = logging.getLogger('my_json')
logger.addHandler(json_handler)
logger.setLevel(logging.INFO)
logger.info('Sign up', extra={'referral_code': '52d6ce'})
  • Performance characteristics when logging at high volume or with large extra fields.
  • Compatibility with alternative JSON libraries (ujson, simplejson) beyond the documented examples.
  • Whether custom formatters can be subclassed without breaking changes across minor versions.
Same gist for agents: .md · .json

What it is and what it does

json-log-formatter wraps Python's standard logging module to emit structured JSON records instead of plain text. It integrates with the logging handler pipeline, converting log messages and extra fields into JSON objects written to files or streams. The library provides three formatter classes: JSONFormatter for minimal output, VerboseJSONFormatter to include standard LogRecord attributes (filename, level, thread info, etc.), and FlatJSONFormatter to stringify complex objects. It supports custom formatters by subclassing and allows swapping the underlying JSON library.

The package is designed for environments where logs feed into aggregation systems like Logstash or cloud logging platforms that parse and index JSON. It works with Django's logging configuration and requires no external dependencies beyond Python 3.9+, making it lightweight to add to existing projects.

Use it for

  • Integrate application logs with Logstash or Elasticsearch for centralized log analysis and monitoring.
  • Add structured metadata (user IDs, request IDs, custom fields) to logs for easier filtering and debugging in production.
  • Replace plain-text logging with JSON to enable automated parsing and alerting in log aggregation pipelines.
  • Configure Django applications to emit JSON logs for cloud logging services that expect structured input.
  • Extend logging with custom fields and transformations by subclassing JSONFormatter for domain-specific requirements.

Worth the install?

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

Worth it

Yes.

The package is lightweight, dependency-free, actively maintained, and solves a concrete problem—structured JSON logging is now standard practice for production systems. Install it if you're already using Python's logging module and need JSON output for log aggregation or cloud platforms.

Install

json-log-formatter on PyPI

Before you install

Low install friction—pure Python wheel with no runtime dependencies. Actively maintained as of June 2026 with recent release history.

Requires Python 3.9 or later.

License in practice

MIT license permits unrestricted use, modification, and distribution in commercial and private projects.

Quickstart

import logging
import json_log_formatter

formatter = json_log_formatter.JSONFormatter()
json_handler = logging.FileHandler(filename='/var/log/my-log.json')
json_handler.setFormatter(formatter)

logger = logging.getLogger('my_json')
logger.addHandler(json_handler)
logger.setLevel(logging.INFO)
logger.info('Sign up', extra={'referral_code': '52d6ce'})

Verify before relying

  • Performance characteristics when logging at high volume or with large extra fields.
  • Compatibility with alternative JSON libraries (ujson, simplejson) beyond the documented examples.
  • Whether custom formatters can be subclassed without breaking changes across minor versions.

Package facts

LicenseMIT permissive
Python supportSupports the current Python release >=3.9
Install frictionLow. Pure-Python wheel
Runtime dependenciesNone
MaintenanceActively maintained 67 days since the last release
Last repo commit
First released
Downloads3,134,411 / month, #2,734 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Intended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Topic :: Software Development :: Libraries :: Python Modules

Evidence: json_log_formatter-1.2.1-py3-none-any.whl

Tags

Capabilities
json log formatterstructured logging pythonlogstash integrationjson logging handlerlog aggregation formattingstructured log outputpython json logs
Topics
loggingstructured-logsjson-output

Let your AI agent find packages like this

Example. Real query, live index.

An agent finds packages by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language. Give your agent the search over MCP.

More Python Modules 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
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
PyYAML Worth it
PyPI · Python Modules · released Sep 2025

PyYAML parses and emits YAML 1.1 data format, enabling serialization and deserialization of configuration files and Python objects to and from human-readable YAML text.

MITcompiled wheel · 3.8+
1.2Bdownloads / mo
pydantic Worth it
PyPI · Python Modules · released May 2026

Pydantic validates Python data structures against type hints, coercing and checking input at runtime to ensure it matches a declared schema.

MITpure Python · 3.9+
1.1Bdownloads / mo
annotated-types Worth it
PyPI · Python Modules · released Jul 2026

Provides reusable metadata objects for use with PEP-593 `typing.Annotated` to express common constraints like bounds, collection sizes, and predicates on types.

Install it if you use or build libraries that need to express type constraints in a standardized, inspectable way—or if you want to annotate your own types with…

MITpure Python · 3.10+
871.3Mdownloads / mo
typing-inspection Worth it
PyPI · Python Modules · released Aug 2026

Provides runtime tools to inspect and introspect Python type annotations, enabling programmatic examination of type hints at execution time.

MITpure Python · 3.10+
783.0Mdownloads / mo

See also logstash_formatter · mo-logs · python-json-logger · jsonformatter · logging-json · logzero · python-logstash · json-logging · logdna · daiquiri