bestconfig
Setup your project config easily
What it is and what it does
bestconfig is a configuration management library that scans your project directory for config files in multiple formats—YAML, JSON, INI, environment files, Python modules, and CFG—and merges them into a single unified configuration object. It provides flexible access patterns: dot notation (config.logger.mode), dictionary syntax (config['logger']['mode']), and a get() method that supports nested key paths (config.get('logger.mode')) and type casting (config.int('PORT'), config.list('PRICES')).
The package automatically discovers common config file names (config.yaml, settings.json, .env, etc.) and environment variables, then exposes them through a single interface. It also supports runtime manipulation via set(), insert(), and update_from_locals() methods, and includes validation through assert_contains(). The library depends only on PyYAML for parsing, keeping installation lightweight.
Use it for:
- Load database credentials and connection settings from .env files and YAML configs in a single Config object.
- Access nested configuration values like database.host and database.port using dot notation without manual dictionary traversal.
- Merge environment-specific configs (dev.yaml, prod.yaml) with shared settings and environment variables at startup.
- Type-cast config values to int, float, list, or dict automatically to avoid string-to-type conversion boilerplate.
- Validate that required configuration keys exist before application startup using assert_contains().
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Loads configuration from multiple file formats (.yaml, .json, .ini, .env, .py, .cfg) and environment variables into a unified interface with dot-notation and dictionary access.
No. The package is abandoned (last commit 2023-04-17, 1215 days ago) with no active maintenance, so security patches and bug fixes are unlikely. While the core functionality is straightforward and low-friction to install, the lack of maintenance makes it a poor choice for new projects; consider actively maintained alternatives like python-dotenv, pydantic-settings, or dynaconf instead.
Install
bestconfig on PyPI
pip
pip install bestconfiguv
uv add bestconfigpoetry
poetry add bestconfigInstalling bestconfig
Before you install
Low install friction with a single runtime dependency (PyYAML). However, the package is in abandoned status with no commits since 2023-04-17, so maintenance and bug fixes are not expected.
License in practice
MIT license is permissive, allowing free use, modification, and distribution with minimal restrictions.
Quickstart
pip install bestconfig
from bestconfig import Config
config = Config("myconfig.json")
logger_mode = config.get('logger.mode')
port = config.int('PORT')
Verify before relying
- Whether Python version support is truly unspecified or if there are undocumented compatibility constraints.
- Whether the package handles circular imports correctly when scanning .py files for configuration.
- Performance characteristics when merging many configuration sources or accessing deeply nested keys.
Package facts
| License | MIT (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 1 — PyYAML |
| Maintenance | abandoned — 1,215 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 89,380/month — #13,663 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: bestconfig-1.3.6-py3-none-any.whl
Tags
More Utilities packages
Converts domain names between Unicode and…
permissive · top 100 on PyPI
charset-normalizerDetects and normalizes text encoding from…
permissive · top 100 on PyPI
setuptoolsSetuptools is a Python build backend and…
permissive · top 100 on PyPI
pluggyPluggy provides a plugin system that lets you…
permissive · top 100 on PyPI
PygmentsPygments is a syntax highlighter that colorizes…
permissive · top 100 on PyPI
sixSix provides utility functions to write Python…
permissive · top 100 on PyPI
donfigDonfig provides a unified configuration system…
permissive · top 5,000 on PyPI
simple-settingsLoads and manages application settings from…
permissive · top 15,000 on PyPI
yaml-configReads configuration from YAML files and…
unclear · top 5,000 on PyPI
yacmanYacman provides a Python interface for reading,…
permissive · top 15,000 on PyPI
typed-configReads typed configuration from multiple sources…
permissive · top 15,000 on PyPI
pyaml-envParses YAML configuration files and resolves…
permissive · top 15,000 on PyPI
dotenvLoads environment variables from a .env file…
unclear · top 5,000 on PyPI
yacsYACS is a lightweight configuration management…
permissive · top 5,000 on PyPI
python-decoupleReads configuration parameters from environment…
permissive · top 5,000 on PyPI
dynaconfDynaconf manages application configuration…
permissive · top 5,000 on PyPI