# joke2k/django-environ

Django-environ allows you to utilize 12factor inspired environment variables to configure your Django application.

Repository: https://github.com/joke2k/django-environ
Canonical: https://ross.abutalabs.com/products/django-environ
Homepage: https://django-environ.readthedocs.io
Language: Python
License: MIT
License Family: permissive
Topics: python, django, twelve-factor, settings, hacktoberfest
Last push: 2026-08-26T17:43:36+00:00

## Health v2 (maintenance only)
Score: 87/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 99, release rhythm 65, longevity 100
- inputs: {"age_days": 4901, "days_push": 7, "days_rel": 76, "gap_med": 120, "n_releases_24m": 4}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 3165, forks 340 (observed 2026-08-28T04:07:46.669040+00:00)

## What it is
django-environ is a Python package that lets you configure Django applications using environment variables following the Twelve-Factor methodology. It provides type casting, .env file loading, and URL parsing for database, cache, and email connection strings.

## Use cases
- manage django settings with environment variables
- load configuration from a .env file in django
- parse database url strings into django database settings
- apply twelve-factor app configuration to django
- cast environment variables to bools, ints, and lists in django settings
- keep secrets like secret_key out of django source code

## When to choose
- you want 12factor-style environment-based configuration for a Django project
- you need to parse DATABASE_URL or CACHE_URL style connection strings into Django settings
- you want typed casting and defaults for environment variables in settings.py

## When to avoid
- you are not using Django (consider python-dotenv or pydantic-settings instead)
- you prefer file-based or static settings without environment variables
- you need configuration management for non-Python infrastructure

## Facets
- artifact type: library
- maturity: active
- function: configuration-management, developer-tools
- domain: web-development, developer-tools, backend
- platform: python
- tags: django, environment-variables, twelve-factor, settings, env-file, 12factor, web-server

## Member repositories
- joke2k/django-environ (main) score 87

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:07:46.669040+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T07:25:11.360049+00:00, confidence not recorded.
  - readme: https://github.com/joke2k/django-environ (fetched 2026-08-28T04:07:46.669040+00:00, sha 5d3d601dec04)
  - registry_pypi: https://pypi.org/pypi/django-environ/json (fetched 2026-08-29T09:40:23.591052+00:00, sha e4137bd62ec2)
- Data as of 2026-08-30T08:39:29.467469+00:00.
