Dev and Config, free, by Pivotal Labs
Compare two .env files without pasting secrets into a website
Paste two environment files and see which keys are missing from either side, which are duplicated and which are empty. The secrets stay in your browser, which is the only acceptable arrangement for this.
Loading Env File Diff & Linter...
What Env File Diff & Linter does
Paste two .env files, see keys missing from either side, duplicates and blank values. Secrets never leave your browser.
Doing this job well
It works on my machine is, more often than anything else, a missing environment variable. The application starts, most of it behaves, and one feature fails in a way that looks like a bug in the code rather than an absence in the configuration. Comparing the two files takes a minute and is skipped because it feels beneath the problem.
The failure modes are specific and worth knowing. A key present in one environment and absent in the other is the obvious one. A key present in both but empty in one is worse, because the application starts happily and fails later at the point of use. A key defined twice, where the second definition silently wins, is worst of all, because the file appears to say something it does not do.
Which is why the comparison should be about keys rather than values. You almost never want to know that the production database password differs from the local one; you want to know that production has a key local does not. Anything that surfaces the shape of the difference without dwelling on the contents is doing the useful half of the job.
The reason to be firm about where this runs should be obvious and frequently is not. An environment file is the single most sensitive text file in most projects: API keys, database credentials, signing secrets, all in plain text with no protection but the file system. Pasting one into a web based diff tool sends every one of those to somebody else's server, and there is no way to take it back afterwards. A secret that has been transmitted is a secret that needs rotating, whatever the tool promised.
That is not a hypothetical concern in this organisation. A personal access token appeared in a chat transcript here and has been on the outstanding list ever since, and the lesson recorded at the time was the right one: a value that has been somewhere it should not be is exposed, regardless of where it was not written down.
This one runs entirely in the page. Nothing is transmitted, nothing is stored, and closing the tab is the whole of the cleanup. That constraint is the reason it is worth building rather than using one of the many that already exist.
Common questions
Are my secrets uploaded?
No, and that is the entire reason this exists. Everything happens in your browser. Nothing is transmitted and nothing is stored.
Does it compare values or just keys?
The keys are the useful comparison. You rarely need to know that two passwords differ; you need to know that one environment has a key the other does not.
Why does it flag empty values?
Because a key that is present but empty is worse than one that is missing. The application starts normally and then fails later, at the point of use, looking like a code bug.
What about a key defined twice?
It flags those too. A duplicate where the second definition silently wins means the file appears to say something it does not actually do.
I already pasted a .env into another web tool. Is that a problem?
Treat those values as exposed and rotate them. A secret that has been transmitted needs replacing regardless of what the tool promised about retention.
Related applets
Built by Pivotal Labs
We build software, and this is a small piece of it.
Pivotal Labs is a software development and product management team. The applets on this site are the offcuts, the small things we build for ourselves and give away. The work we are paid for looks rather different.
See what Labs buildsFurther reading

Scaled CS: what it actually means and when you need it

Defining Success Before the Sale: The CS Conversation That Usually Starts Too Late

Expansion revenue is a Customer Success responsibility. Here's why most teams aren't ready for it.

The CS Leader's First 90 Days: Why Fixing Things Too Fast Is the Fastest Way to Get Things Wrong

The CS Tech Stack: What to Buy, and in What Order

