Envless ships as three separate npm packages plus two Python ones, two Ruby ones and two PHP ones. @goenvless/cli is the envless binary and nothing else, @goenvless/env is the package your application imports to load its variables, @goenvless/sdk is the API client for administering a workspace from code, envless-sdk, on PyPI and on RubyGems, is the same API client for Python and for Ruby, envless-env, on PyPI and on RubyGems, is the runtime a Python or Ruby app loads its variables with, and envless/sdk and envless/env, on Packagist, are the API client and the runtime for PHP. Apart from the three runtimes, each of which builds on the SDK of its language, none of them depends on the others, so install whichever surfaces fit:
- CLI (
@goenvless/cli): theenvlessbinary, sologin/link/sync/run/typesand the rest of the workspace commands. Binary only, its single export is./package.json, so there is nothing toimportfrom it. Every command is documented under CLI. - Env (
@goenvless/env): nine entrypoints.import { env } from '@goenvless/env/server'andimport { env } from '@goenvless/env/client'are the two you read variables through, the bare@goenvless/envroot addsloadand the crypto helpers to an untyped, unfilteredenvfor scripts,@goenvless/env/registeris the preload,@goenvless/env/nextand@goenvless/env/viteare the build adapters,@goenvless/env/eslintis the lint plugin,@goenvless/env/edgeis the fetch-only loader whoseload(options)returns a plain record, and@goenvless/env/cryptois the encryption recipe on its own:encrypt,decrypt,encryptWithKey,decryptWithKey,workspaceKey,importWorkspaceKey,passphraseStrengthandENCRYPTION_PARAMETERS./registeris the only entry that loads on import. From/serveryou either preload it or awaitload()yourself, and/clientreads whatever the Next or Vite adapter inlined at build time./client,/edgeand/cryptoare the three built free of Node built-ins, so they are the ones that run in a browser, a worker or on an edge runtime. No binary, installing it globally gives you noenvlesscommand. Every entrypoint is documented under Env. - SDK (
@goenvless/sdk):import { createClient } from '@goenvless/sdk'to manage products, projects, environments, variables, versions, members, roles, keys and webhooks from code. It never loads variables into your app and never touches the filesystem. Every method is documented under SDK, and the HTTP surface beneath it under API. - Python SDK (
envless-sdk, on PyPI):from envless import envlessfor the same methods in snake_case, withEnvlessfor synchronous code andAsyncEnvlessfor asyncio and trio. It administers a workspace and never loads variables into your app: a Python service gets those fromenvless-env,envless run -- python app.pyorenvless sync. Every method is documented under Python. - Python runtime (
envless-env, on PyPI):import envless_env.register, thenfrom envless_env.server import env, to load and read variables in a Python app, with the same loader, cache and rules as@goenvless/envand integrations for Django, Flask, FastAPI and pydantic-settings. Every module is documented under Python runtime. - Ruby SDK (
envless-sdk, on RubyGems):require "envless/sdk", thenEnvless.variablesand the rest for the same methods in snake_case, with RBS signatures and no runtime dependencies. It administers a workspace and never loads variables into your app: a Rails or Rack service gets those fromenvless-env,envless run -- bin/rails serverorenvless sync. Every method is documented under Ruby. - Ruby runtime (
envless-env, on RubyGems):require "envless/env/load", thenEnvless.env[:DATABASE_URL], to load and read variables in a Ruby app, with the same loader, cache and rules as@goenvless/env, a Railtie for Rails and RBS signatures. Everything is documented under Ruby runtime. - PHP SDK (
envless/sdk, on Packagist):new Envless\Envless(), then$envless->variablesand the rest for the same methods under their TypeScript names, with a PHPStan and Psalm type for every request and response. It administers a workspace and never loads variables into your app: a PHP service gets those fromenvless/env,envless runorenvless sync. - PHP runtime (
envless/env, on Packagist):Envless\Env\Env::load(), thenEnv::get('DATABASE_URL'), to load and read variables in a PHP app, with the same loader, cache and rules as@goenvless/env, recipes for Laravel, Symfony and PHP-FPM, and a generator for typed classes. Everything is documented under PHP runtime.
Install the CLI
A global install adds the envless binary to your PATH. Best for login, link, and ad-hoc commands across multiple projects.
npm i -g @goenvless/cli@latestpnpm add -g @goenvless/cliyarn global add @goenvless/clibun add -g @goenvless/cliTo pin the CLI per-project instead of globally, add @goenvless/cli as a dev dependency first. The envless binary ships with that package, so until it is installed there is nothing in node_modules/.bin for npx to run:
npm i -D @goenvless/cli
npx envless --helpInstall Env
Pin Env to your project so every contributor and your CI run the same version. This is the package you need if you're using the import { env } mode.
npm i @goenvless/env@latestpnpm add @goenvless/envyarn add @goenvless/envbun add @goenvless/envInstall the TypeScript SDK
Only needed when you administer a workspace from code. Skip it if you're just consuming variables.
npm i @goenvless/sdk@latestpnpm add @goenvless/sdkyarn add @goenvless/sdkbun add @goenvless/sdkInstall the Python SDK
Only needed when you administer a workspace from Python. A Python app that just reads its variables needs the Python runtime below, or the CLI, not this.
pip install envless-sdkuv add envless-sdkpoetry add envless-sdkIt needs Python 3.10 or newer. See Installation in the Python docs for the requirements and a first call.
Install the Python runtime
For a Python app that loads its own variables at boot.
pip install envless-envuv add envless-envpoetry add envless-envIt needs Python 3.10 or newer and installs envless-sdk alongside. See the Python runtime for loading at boot and the framework integrations.
Install the Ruby SDK
Only needed when you administer a workspace from Ruby. A Rails app that just reads its variables needs the Ruby runtime or the CLI, not this.
bundle add envless-sdkgem install envless-sdkIt needs Ruby 3.2 or newer and nothing else. See Installation in the Ruby docs for the requirements and a first call.
Install the Ruby runtime
For a Ruby app that loads its own variables at boot.
bundle add envless-envgem install envless-envIt needs Ruby 3.2 or newer and installs envless-sdk alongside. See the Ruby runtime for loading at boot and the Rails integration.
Install the PHP SDK
Only needed when you administer a workspace from PHP. A Laravel or Symfony app that just reads its variables needs the PHP runtime or the CLI, not this.
composer require envless/sdkIt needs PHP 8.2 or newer with the curl, json and openssl extensions, which almost every PHP build ships with, and no other Composer package. See the PHP SDK for the client, every method and its examples.
Install the PHP runtime
For a PHP app that loads its own variables at boot.
composer require envless/envIt needs PHP 8.2 or newer and installs envless/sdk alongside. See the PHP runtime for loading at boot and the Laravel and Symfony setups.
Verify
Check whichever packages you installed. Only the CLI ships a command to run.
envless --versionnode -p "require('@goenvless/env/package.json').version"node -p "require('@goenvless/sdk/package.json').version"python -c "import envless; print(envless.__version__)"python -c "import envless_env; print(envless_env.__version__)"ruby -renvless/sdk -e 'puts Envless::VERSION'ruby -renvless/env -e 'puts Envless::Env::VERSION'php -r 'require "vendor/autoload.php"; echo Envless\Envless::VERSION, PHP_EOL;'php -r 'require "vendor/autoload.php"; echo Envless\Env\Env::VERSION, PHP_EOL;'What's next
Log in
Authenticate via the browser flow.
Link a project
Bind this directory to a workspace and environments.
Concepts
Skim the five ideas that show up everywhere.
Going deeper
The full command surface, and what each one does, is laid out on the site.