Simple KEY=value lines
In .env → JSON mode, each non-empty line matching NAME=value becomes a JSON property. Names start with a letter or underscore followed by alphanumerics. Optional single or double quotes around values are stripped on import.
JSON back to dotenv
JSON → .env expects a flat object with string values and emits one key=value line per entry without adding quotes. Comments, export prefixes, and variable interpolation are not parsed — paste only the subset you need to transform.
Questions
Should I paste production secrets here?
Conversion runs locally, but .env files often hold API keys. Prefer sanitized samples on shared machines and rotate anything that might have appeared on screen.
Where do I pretty-print the JSON output?
After converting to JSON, open the JSON formatter and validator if you want two-space indentation or minify.