.env Converter
Convert between .env (dotenv), JSON and YAML. Handles comments, quotes and export syntax, all processed inside your browser.
How to Use
Enter Text
Paste your .env, JSON, or YAML into the input field.
Pick Formats & Convert
Choose the "From" and "To" formats, then press Convert.
Copy or Download
Copy the result or download it as a file.
About the .env Converter
A web tool that converts dotenv (.env) environment files to and from JSON and YAML config files. A custom parser correctly handles dotenv-specific syntax such as comments (#), single/double quotes, and the export prefix. No eval is used; YAML is processed with the version-pinned js-yaml 4.1.0. Every conversion runs entirely in your browser, so your input is never sent to any server.
Features
- Six-way ConversionConvert freely between .env, JSON and YAML in any combination.
- dotenv Syntax AwareCorrectly parses comments, inline comments, quotes and export syntax.
- Safe Custom ParserNo eval, ever. A dedicated parser plus a pinned js-yaml version for YAML.
- Fully In-BrowserInput data never leaves your device; conversion happens locally.
Use Cases
- Migrate .env values into docker-compose or other YAML configs
- Manage CI/CD environment variables as JSON
- Expand YAML config into a .env file for local development
- Convert config files between JSON and YAML
- Review and tidy up a list of environment variables
FAQ
Are my environment variables sent anywhere?
Does it handle comments and export syntax?
How are quoted values handled?
Can nested JSON/YAML be converted to .env?
What happens to value types (numbers, booleans)?
Can I use it on my smartphone?
Feedback
Missing a feature, or getting a result that looks wrong? Let us know — we improve our tools based on your feedback.