typer-config
Utilities for working with configuration files in typer CLIs.
What it is and what it does
typer-config is a decorator-based utility library that extends typer CLI applications with configuration-file support. Instead of passing many command-line options every time you run a CLI tool, you can write those parameters once in a YAML, TOML, JSON, or Dotenv file and reference it with a single --config parameter. The package provides decorators like @use_yaml_config, @use_toml_config, @use_json_config, and @use_dotenv_config that inject a --config option into your typer command, plus a generic @use_config decorator for custom loaders.
The package depends only on typer and works with modern Python versions (3.10 through 3.14). Optional dependencies for specific file formats can be installed separately, so you only add what you need. It's designed for typer applications with many parameters where repeatedly typing long command lines becomes impractical.
Use it for:
- Replace repetitive multi-option CLI invocations with a single config file reference for complex tools.
- Store environment-specific settings (dev, staging, prod) in separate YAML or TOML files for the same CLI.
- Let non-technical users configure CLI tools by editing a simple configuration file instead of memorizing command syntax.
- Manage dotenv-based configuration for CLI tools that read from environment files.
- Prototype CLI parameter sets and reuse them across multiple runs without retyping.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Adds configuration-file support to typer CLI applications, letting you replace long command-line arguments with a single config file parameter.
Yes. Low install friction, active maintenance, no known vulnerabilities, and a clear use case for typer users managing complex CLIs. The MIT license poses no restrictions. Install if you build typer applications with many parameters or want to let users configure them via files.
Install
typer-config on PyPI
pip
pip install typer-configuv
uv add typer-configpoetry
poetry add typer-configInstalling typer-config
Before you install
Low friction: pure Python wheel with a single runtime dependency (typer). Active maintenance status with recent release.
License in practice
MIT license permits unrestricted use, modification, and distribution with minimal restrictions.
Quickstart
pip install typer-config
import typer
from typer_config import use_yaml_config
app = typer.Typer()
@app.command()
@use_yaml_config()
def main(foo: str):
print(foo)
if __name__ == "__main__":
app()
Requires Python 3.10 or later.
Verify before relying
- Whether optional dependencies (YAML, TOML, Dotenv libraries) are automatically installed or must be specified separately.
- Performance characteristics when loading large configuration files.
- Support for nested or complex configuration structures beyond simple key-value pairs.
Package facts
| License | MIT (permissive) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 1 — typer |
| Maintenance | actively maintained — 166 days since the last release |
| First released | |
| Downloads | 307,080/month — #7,780 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: typer_config-1.5.1-py3-none-any.whl
Keywords: typer, config, configuration, configuration-file, yaml, toml, json, dotenv, cli
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
typer-injectorAdds FastAPI-style dependency injection to…
permissive · top 15,000 on PyPI
jsonargparsejsonargparse creates command-line interfaces…
permissive · top 5,000 on PyPI
typer-cliThis package is a deprecated migration shim…
permissive · top 15,000 on PyPI
sphinxcontrib-typerA Sphinx extension that auto-generates…
permissive · top 15,000 on PyPI
typer-slimtyper-slim is a deprecated migration shim that…
permissive · top 5,000 on PyPI
django-typerBuilds type-safe Django management command CLIs…
permissive · top 15,000 on PyPI
yaml-configReads configuration from YAML files and…
unclear · top 5,000 on PyPI
lib-layered-configLoads and merges configuration from multiple…
permissive · top 15,000 on PyPI
vyper-configVyper provides a unified configuration system…
permissive · top 15,000 on PyPI