Skip to main content

Installation

Env Core can be installed using your favorite package manager. Choose the one you prefer:
npm install env-core

Requirements

Env Core requires Node.js version 16.0.0 or higher.
Env Core works with both ESM (import) and CommonJS (require) module systems.

Dependencies

Env Core has minimal dependencies:
  • dotenv - For parsing .env files
No additional configuration is needed - Env Core works out of the box with your existing .env files.

TypeScript support

If you’re using TypeScript, Env Core includes full type definitions. No need to install separate @types packages!
import { validateEnv } from 'env-core';
import type { ValidatedEnv, EnvSchema } from 'env-core';
The library provides complete type inference for your environment variables based on your schema definition.

Verify installation

You can verify that Env Core is installed correctly by importing it in your project:
import { validateEnv } from 'env-core';

console.log(typeof validateEnv); // 'function'

Next steps

Quick start guide

Learn how to use Env Core in your project with a step-by-step guide

Build docs developers (and LLMs) love