dotenvx

Documentation

a better dotenv–from the creator of dotenv.

Getting Started

# install with Homebrew and then use the dotenvx command
brew install dotenvx/brew/dotenvx
dotenvx help
  • run anywhere (cross-platform)
  • multi-environment
  • encrypted envs

Languages

Node.js

Use dotenvx with Node.js

Node.js Guides

Python

Use dotenvx with Python

Python Guides

Ruby

Use dotenvx with Ruby

Ruby Guides

Go

Use dotenvx with Go

Go Guides

PHP

Use dotenvx with PHP

PHP Guides

Rust

Use dotenvx with Rust

Rust Guides

Frameworks

Astro

Use dotenvx with Astro

Astro Guides

Express.js

Use dotenvx with Express

Express Guides

Next.js

Use dotenvx with Next.js

Next.js Guides

Remix

Use dotenvx with Remix

Remix Guides

Flask

Use dotenvx with Flask

Flask Guides

Sinatra

Use dotenvx with Sinatra

Sinatra Guides

Rocket

Use dotenvx with Rocket

Rocket Guides

Platforms

Digital Ocean

Use dotenvx with Digital Ocean

Digital Ocean Guide

Docker

Use dotenvx with Docker

Docker Guide

Fly

Use dotenvx with Fly

Fly Guide

Heroku

Use dotenvx with Heroku

Heroku Guide

Netlify

Use dotenv with Netlify

Netlify Guide

Vercel

Use dotenvx with Vercel

Vercel Guide

Railway

Use dotenvx with Railway

Railway Guide

Render

Use dotenvx with Render

Render Guide

CI/CDs

GitHub Actions

Use dotenvx with GitHub Actions

GitHub Actions Guide

Package Managers

NPM

Use dotenvx with npm

NPM Guide

npm

PNPM

Use dotenvx with pnpm

PNPM Guide

pnpm

Process Managers

PM2

Use dotenvx with pm2

PM2 Guide

Monorepos

Nx

Use dotenvx with Nx

Nx Guide

Turborepo

Use dotenvx with Turborepo

Turborepo Guide

Concepts

.env

The .env file separates your secrets from code.

.env.keys

The .env.keys file holds your private decryption keys.