Skip to main content

Diff Viewer

The Diff Viewer lets you compare any two .env* files side-by-side to see what variables have been added, removed, or changed between environments.

Opening the Diff Viewer​

Click the Compare icon in the Environment Files panel toolbar, or run ENV Manager: Compare Two .env Files from the Command Palette.

You'll be prompted to pick two files:

  1. The left file (base)
  2. The right file (target)

What the Diff Shows​

The diff viewer uses VS Code's built-in diff editor, so you get the same familiar interface used for git diffs:

  • Green lines — keys present in the right file but not the left (additions)
  • Red lines — keys present in the left file but not the right (deletions)
  • Yellow lines — keys present in both but with different values (changes)

Values are shown with masking (••••) for secret-looking keys so sensitive data isn't exposed in the diff view.

Common Use Cases​

Checking what changed between environments: Compare .env.development and .env.production to find keys that exist in development but are missing from production.

After pulling from cloud: After a Vercel or Doppler sync, compare your local .env with a backup to verify only expected changes came through.

Onboarding: Compare .env.example with .env to see exactly which variables you still need to fill in.