Start a project

Tool 95 of 100 · DevOps

.env File Checker

Paste a .env file and find duplicates, bad names, broken quotes, missing keys and values that look like live credentials, then get a safe .env.example to commit.

.env File Checker at a glanceIllustration: 1, .env + example; 2, processed in your browser; 3, Missing keys + secrets..env File Checker1.env + example3Missing keys + secrets2In yourbrowser
1 .env + example 2 processed on your device 3 Missing keys + secrets

.env File Checker

.env

.env.example (optional)

Safe .env.example

Generated .env.example (secrets blanked)

Results

    NameValueStatusExample file

    01

    What it does

    Parses .env files like dotenv, compares them with .env.example, flags problems and likely live secrets, and writes a safe example.

    • dotenv parsing: export, quotes, multi-line values and comments
    • ${VAR} expansion across the whole file
    • Compare with .env.example: missing and extra keys
    • Spots likely secrets: keys, tokens and passwords

    02

    Private by design

    Everything happens in your browser. Nothing you type, paste or upload is sent anywhere, and it keeps working offline once the page has loaded.

    03

    What you get

    Findings and a .env.example, with a Copy and a Download button on every result.

    • .env
    • Secrets
    • DevOps
    • Config

    Why it matters

    Environment files hold the settings and secrets an app needs, and they go wrong quietly: a duplicate key where the second one wins, a missing quote that swallows the next line, or a key in .env.example that nobody set in production.

    This checker parses the file the way dotenv does, explains every problem and writes a .env.example with the values removed, so you can commit the shape of your config without the secrets. Values stay on the page and are masked on screen unless you choose to show them.

    How it works

    1. InputA .env file and its example
    2. In your browserParsed like dotenv, values compared
    3. OutputMissing keys, risky secrets and a safe example

    Where it fits in a designer's workflow

    1. Plan
    2. Design
    3. Build
    4. Test
    5. Launch
    Deploying to a new server.

    By the numbers

    The sample .env (10 keys) against its .env.example (8)Missing from .env: 1; Empty but required: 1; Not in the example: 2; Look like real secrets: 1; Syntax issues: 4Missing from .env1Empty but required1Not in the example2Look like real secrets1Syntax issues4
    Found by this tool's own parser and checks. Config belongs in the environment, not the code, but a key missing from one server is the classic 'works on my machine' bug. Source: The Twelve-Factor App: config.
    Show the numbers as a table
    CheckCount
    Missing from .env1
    Empty but required1
    Not in the example2
    Look like real secrets1
    Syntax issues4

    How to use it

    1. Paste your .env file (values are masked).
    2. Optionally paste .env.example to compare.
    3. Fix the problems listed.
    4. Download the generated .env.example to commit.

    FAQ

    Is my .env uploaded?

    No. It's parsed in your browser and values are masked on screen. Still, never paste production secrets into sites you don't trust.

    Which value wins if a key appears twice?

    With dotenv, the last one in the file. Other loaders may take the first, which is why duplicates are flagged.

    How does it spot secrets?

    From key names (SECRET, TOKEN, PASSWORD, KEY), known prefixes such as sk_live_ and ghp_, and long random-looking values.

    Should .env be committed?

    No. Add it to .gitignore and commit .env.example instead.

    Work with me

    Want a site that gets these right?

    I build fast, accessible websites and web apps that pass these checks from day one. Tell me about your project and I'll reply personally with honest next steps.

    All developer tools · Back to leej.uk