deftools.io DevOps & CLI

📝 .editorconfig Generator

Generate .editorconfig files visually. Configure indentation, charset, line endings, and file-type rules, then copy the ready-to-use config.

Root settings [*]
0 sections
     

About this tool

EditorConfig is a standard that keeps coding styles consistent across editors and IDEs. By placing an .editorconfig file in your project root, you define indentation, line endings, charset, and whitespace rules once — then every contributor's editor picks them up automatically (VS Code, JetBrains, Vim, Emacs, and 20+ others support it natively or via plugins).

Use this generator to build the file visually instead of typing properties by hand. The root [*] section defines default rules; add per-file-type sections when some files need different settings — for example, YAML requires spaces (tabs are invalid), while Makefiles require real tabs.

Example output with a few sections: root = true, [*] with indent_style = space and indent_size = 2, plus a [Makefile] override with indent_style = tab.

FAQ

Which editors support EditorConfig?

VS Code, IntelliJ / WebStorm / PyCharm (built in), Vim (plugin), Emacs (plugin), Sublime Text (plugin), Atom, Neovim, and many more. Over 20 editors either bundle support or have a one-click plugin.

Where do I put the .editorconfig file?

Place it in the root of your repository. Editors walk up the directory tree from the file being edited, so rules cascade — a .editorconfig in a subdirectory overrides the root settings for files in that subtree.

Do I need tabs for Makefiles?

Yes. Makefiles require real tab characters for recipe lines. Use a <code>[Makefile]</code> section with <code>indent_style = tab</code> to enforce this, while keeping spaces for the rest of the project.

What files should I add .editorconfig to?

Every project — open-source or private — benefits from having one. It prevents tab-vs-space arguments, avoids mixed line endings, and guarantees that every contributor uses the same formatting rules without manual setup.

Related devops & cli tools

Copied!