python-dotenv
Read key-value pairs from a .env file and set them as environment variables
Install
python-dotenv on PyPI
pip
pip install python-dotenvuv
uv add python-dotenvpoetry
poetry add python-dotenvPackage facts
| License | BSD-3-Clause (permissive) |
| Python support | supports the current Python release (>=3.10) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | none |
| Maintenance | actively maintained — 165 days since the last release |
| Last repo commit | |
| First released | |
| Popularity | one of the 100 most-downloaded packages on PyPI (30-day window, as of 2026-08-13) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-13) |
Evidence: python_dotenv-1.2.2-py3-none-any.whl
Keywords: environment variables, deployments, settings, env, dotenv, configurations, python
About python-dotenv
from the package's own PyPI description — quoted content, verbatim
python-dotenv
[![Build Status][build_status_badge]][build_status_link] [![PyPI version][pypi_badge]][pypi_link]
python-dotenv reads key-value pairs from a .env file and can set them as
environment variables. It helps in the development of applications following the
12-factor principles.
- Getting Started
- Other Use Cases
- Load configuration without altering the environment
- Parse configuration as a stream
- Load .env files in IPython
- Command-line Interface
- File format
- Multiline values
- Variable expansion
- Related Projects
- Acknowledgements
Getting Started
pip install python-dotenv
If your application takes its configuration from environment variables, like a 12-factor application, launching it in development is not very practical because you have to set those environment variables yourself.
To help you with that, you...
Similar packages
permissive · top 1,000 on PyPI
pydantic-settingspermissive · top 100 on PyPI
ConfigArgParsepermissive · top 1,000 on PyPI
email-validatorpermissive · top 1,000 on PyPI
groqpermissive · top 1,000 on PyPI
zope.interfaceunclear · top 1,000 on PyPI
lazy-object-proxypermissive · top 1,000 on PyPI
poetry-corepermissive · top 1,000 on PyPI
argcompletepermissive · top 1,000 on PyPI
simple-salesforcepermissive · top 1,000 on PyPI