skillfed

django-configurations

A helper for organizing Django settings.

django-configurations v2.5.1 383.1K downloads/30d#7,080 on PyPI1,135
Permissive license BSD AGING released

What it is and what it does

django-configurations replaces Django's module-based settings system with a class-based approach, letting you define settings as Python classes that inherit from a base Configuration class. This enables composition, inheritance, and environment-specific overrides without environment variables or multiple settings files. You define a class (e.g., Dev, Production) with your settings as class attributes, set DJANGO_CONFIGURATION to the class name, and modify your manage.py, wsgi.py, or asgi.py to call django-configurations' starter functions instead of Django's defaults.

The package depends only on django and is designed for projects that want cleaner, more maintainable settings organization. It supports Django 3.2 through 5.0 and Python 3.8 and later, including PyPy. The approach is particularly useful for multi-environment deployments where you need different settings for development, staging, and production without duplicating configuration logic.

Use it for:

  • Organize development, staging, and production settings as separate Configuration subclasses with shared base settings.
  • Use class inheritance to share common settings across environments and override only what differs.
  • Store environment-specific values (database URLs, API keys) as class attributes instead of scattered environment variables.
  • Compose settings from multiple Configuration classes to build complex, reusable configuration hierarchies.
  • Migrate an existing Django project from flat settings.py to a class-based structure for better maintainability.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Organizes Django settings using composable Python classes instead of module-based configuration, enabling environment-specific settings through class inheritance and object-oriented patterns.

Yes, if you want cleaner Django settings organization. The package is stable (Production/Stable status), permissively licensed, has no known vulnerabilities, and low install friction. Maintenance is aging but active; the last commit was recent and the package is not archived. It's a good fit for projects that value object-oriented configuration patterns and multi-environment management.

Install

django-configurations on PyPI

pip

pip install django-configurations

uv

uv add django-configurations

poetry

poetry add django-configurations

Installing django-configurations

Before you install

Low friction install with a single runtime dependency on django. Maintenance status is aging—last commit was 2025-12-15 and the latest release was 2024-03-27, so updates are infrequent but the package remains active and archived status is false.

License in practice

BSD license (permissive) means you can use, modify, and distribute this package freely in commercial and open-source projects with minimal restrictions.

Quickstart

pip install django-configurations

# mysite/settings.py
from configurations import Configuration

class Dev(Configuration):
    DEBUG = True

# manage.py
from configurations.management import execute_from_command_line
execute_from_command_line(sys.argv)

Requires setting DJANGO_SETTINGS_MODULE and DJANGO_CONFIGURATION environment variables, and modifying manage.py, wsgi.py, or asgi.py to use django-configurations' starter functions instead of Django's defaults.

Verify before relying

  • Whether the package supports Django versions beyond 5.0 (classifiers list 5.0 as latest tested).
  • Performance or overhead implications of class-based settings compared to module-based Django settings.

Package facts

License BSD (permissive)
Python support supports the current Python release (<4.0,>=3.8)
Install friction low — pure-Python wheel
Runtime dependencies 1 — django
Maintenance aging — 870 days since the last release
Last repo commit
First released
Downloads 383,130/month — #7,080 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: django_configurations-2.5.1-py3-none-any.whl

Development Status :: 5 - Production/StableFramework :: DjangoFramework :: Django :: 3.2Framework :: Django :: 4.1Framework :: Django :: 4.2Framework :: Django :: 5.0Intended Audience :: DevelopersLicense :: OSI Approved :: BSD LicenseOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Programming Language :: Python :: Implementation :: PyPyTopic :: Utilities

Tags

django settings managementenvironment-specific django configdjango configuration classesdjango settings inheritanceclass-based django settingsdjango configuration compositionmanage django environments
django-settingsconfiguration-managementenvironment-config

More Utilities packages