ZConfig
Structured Configuration Library
What it is and what it does
ZConfig is a configuration library designed for applications that need more structure and type safety than Python's standard ConfigParser. It uses XML-based schemas to define configuration structure, data types, and validation rules. Schemas can import components from Python packages, allowing configuration objects to be arbitrarily complex with values verified against custom constraints. This separation of schema definition from configuration loading makes it well-suited to configuration-intensive applications where multiple packages need to contribute configuration support.
The library is particularly known for its logging configuration support, which integrates directly with Python's logging framework. It supports multiple format styles (classic, format, template, safe-template), custom log handlers, and parameters like delay and encoding. ZConfig has been in active development since 2005 and currently supports Python 3.10 through 3.14, with no known security vulnerabilities.
Use it for:
- Configure Python logging with hierarchical handlers, formatters, and custom styles defined in a schema.
- Build configuration systems for multi-package applications where each package contributes schema components.
- Define typed, validated configuration files with custom conversion functions for application-specific data types.
- Separate configuration schema definition from configuration loading in complex applications.
- Generate documentation for configuration schemas using the built-in Sphinx extension.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
ZConfig is a schema-driven configuration library that parses hierarchical XML-based schemas and loads configuration files with type validation and custom conversion routines.
Yes, if you need structured, schema-driven configuration with type validation and custom conversion routines. The package is stable, has no dependencies, and supports current Python versions. The aging maintenance status (266 days since last release) is not a blocker given the mature, stable nature of the library, but review the Zope Public License 2.1 if proprietary use is a concern. Not necessary if ConfigParser or simpler alternatives meet your needs.
Install
zconfig on PyPI
pip
pip install zconfiguv
uv add zconfigpoetry
poetry add zconfigInstalling ZConfig
Before you install
Low install friction with no runtime dependencies. Maintenance status is aging—last release was 266 days ago—but the package remains actively supported on current Python versions (3.10 through 3.14) with no known vulnerabilities.
License in practice
Licensed under Zope Public License 2.1, which is OSI-approved but less commonly encountered than MIT or Apache 2.0. The license treatment is marked unclear in the fact sheet, so review the full license text if proprietary use or redistribution is a concern.
Quickstart
pip install ZConfig
from ZConfig import configureLoggers
configureLoggers('''
level INFO
PATH STDOUT
format %(levelname)s %(name)s %(message)s
''')
Requires Python 3.10 or later.
Verify before relying
- Whether the XML schema language and conversion function binding model are suitable for your specific configuration complexity.
- Performance characteristics when loading large or deeply nested configuration hierarchies.
- Compatibility with third-party packages that provide ZConfig schema components via entry points.
Package facts
| License | ZPL-2.1 (unclear) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | aging — 266 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 215,204/month — #9,405 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: zconfig-4.3-py3-none-any.whl
Keywords: configuration, structured, simple, flexible, typed, hierarchy, logging
Tags
More Software Development packages
Provides backported and experimental type hints…
permissive · top 100 on PyPI
numpyNumPy provides an N-dimensional array object…
permissive · top 100 on PyPI
fastapiFastAPI is a Python web framework for building…
permissive · top 100 on PyPI
annotated-docProvides a way to document function parameters,…
permissive · top 100 on PyPI
typerTyper builds command-line applications from…
permissive · top 1,000 on PyPI
distlibDistlib provides low-level packaging utilities…
permissive · top 1,000 on PyPI
zope.configurationZope.configuration provides an extensible…
unclear · top 5,000 on PyPI
configProvides hierarchical configuration management…
permissive · top 5,000 on PyPI
zope.schemaDefines structured data schemas for Python…
unclear · top 5,000 on PyPI
zope.structuredtextParses and renders Zope structured text (STX),…
unclear · top 15,000 on PyPI
DocumentTemplateDocumentTemplate implements the Document…
unclear · top 15,000 on PyPI
hierarchical-confLoads configuration from YAML files organized…
unclear · top 15,000 on PyPI
zope.browsermenuProvides browser menu implementation and ZCML…
unclear · top 15,000 on PyPI
lazr.configlazr.config lets you define configuration…
copyleft · top 15,000 on PyPI
zope.exceptionsProvides general-purpose exception classes and…
unclear · top 15,000 on PyPI
zope.contenttypeGuesses MIME types from filenames and body…
unclear · top 15,000 on PyPI