All Tools View Categories About Contact Privacy

Env Variable Counter & Summary

Instant statistics for a .env: counts, empties, duplicates, prefixes, and value lengths.

Runs entirely in your browser — nothing is uploaded.

About Env Variable Counter & Summary

Every .env deserves a quick health check. The Env Variable Counter & Summary produces an instant dashboard: how many keys, how many are empty, which are duplicated, what prefixes dominate, and a value-length histogram to spot suspiciously long secrets.

Paste the file and the numbers appear — no configuration needed. Use it as a gate in CI to catch accidental growth or drift.

Features

  • Core counts: total, non-empty, empty, comment lines, blank lines.
  • Duplicates: keys listed with occurrence count.
  • Prefix breakdown: top 10 prefix groups by key count.
  • Length histogram: buckets 0–8, 9–16, 17–32, 33–64, 65+.
  • Copy or download: CSV-friendly summary.
  • Private: fully client-side.

How to Use

  1. Paste your .env or load the sample.
  2. View the stats instantly.
  3. Copy the summary for tickets or CI logs.

Examples

Example 1 — CI gate. A pipeline step runs the counter and fails if empty count > 0 or duplicate count > 0.

Example 2 — Growth tracking. Weekly runs show the file growing by N keys, prompting a refactor.

Example 3 — Secret audit. The histogram reveals a 200-char value that turned out to be a full certificate instead of a reference.

Example 4 — Prefix hygiene. The breakdown shows 3 different prefix spellings for database keys, prompting standardization.

Benefits

  • Instant: stats in milliseconds.
  • Comprehensive: counts, duplicates, prefixes, lengths.
  • Actionable: highlights exact problems.
  • Private: nothing uploaded.

Frequently Asked Questions

What statistics does this tool show?
Total key-value pairs, empty values, duplicate keys (with counts), top prefixes, value-length histogram, and comment/blank line counts.
How are duplicates counted?
Every occurrence after the first is a duplicate. The report lists each duplicated key and how many times it appears.
What is a prefix breakdown?
The text before the first underscore (e.g., DB_, NEXT_PUBLIC_) with the number of keys in each group.
Is anything uploaded?
No. Counting is a client-side analysis of the pasted file.