EditorConfig Generator

Pick indent, line ending, and whitespace rules per file glob and get a ready-to-use .editorconfig file.

Use the EditorConfig Generator

.editorconfig


            

Summary

This tool builds a .editorconfig file from a set of file-pattern sections, each with its own indent style, indent size, line ending, charset, and whitespace rules. EditorConfig keeps coding style consistent across editors and IDEs, so a shared config saves teams from mixed tabs and spaces or inconsistent line endings. Add as many sections as needed, then copy the output or download it as .editorconfig and drop it in your project root.

How it works

  1. Toggle "root = true" if this file should stop EditorConfig from searching parent directories.
  2. Edit the default sections or add a new one with "Add Section".
  3. Set a glob pattern for each section, such as * or *.py or {package.json,.travis.yml}.
  4. Choose indent style, indent size, end of line, charset, and whitespace options for that pattern.
  5. Copy the generated text or download it as a .editorconfig file.
  6. Place the file in your project root (or any subfolder it should apply to).

Use cases

  • Standardize indentation across a team using mixed editors (VS Code, JetBrains, Vim).
  • Force LF line endings for a repo shared between Windows and Unix contributors.
  • Keep tabs for Makefiles or Go files while using spaces everywhere else.
  • Strip trailing whitespace on most files but keep it for Markdown line breaks.
  • Bootstrap a new repository with sane default formatting rules.
  • Document per-language formatting choices in one readable file.

Frequently Asked Questions

Last updated: 2026-09-09 · Reviewed by Nham Vu