Tools

.gitignore generator

Combine GitHub's official .gitignore templates — Node, Python, Go, Unity, macOS, JetBrains and more — into one file.

Runs in your browserCode converters175.8K
Free

Input

0 B

Result

The result will appear here.

Most projects need more than one .gitignore template: the language, the framework, the editor and the operating system each leave their own files behind. Type the names — node, python, vscode, macos — and this tool joins the matching templates from github/gitignore, the collection GitHub offers when you create a repository, into one file with a section per template. The templates are a dated snapshot bundled with the page, so nothing is fetched while you use it, and the header of the output says which commit it came from.

How it works

  • Names are matched without regard to case, and common aliases work: py, golang, vscode, idea, mac, next.js, ios (Swift plus Xcode) and so on.
  • A name that matches nothing gets a suggestion — pyhton is answered with Python — and the other names are still combined.
  • Duplicate removal drops a rule already listed by an earlier template, except when a ! rule in between could re-include what it ignores; then the repeat stays, because it re-ignores on purpose.
  • Run it with an empty input to see every template name in the snapshot.

Where your data goes

Nowhere. This tool runs entirely in your browser: the text you paste is processed by the page and is never transmitted to a server or written to a log.

This tool is free and needs no account. Its results exist only in your open page and are not saved anywhere.

What it costs

This tool is free, with no sign-in and no points.

Common questions

Which templates are available?
Fifty-six of the most used ones: languages such as Node, Python, Go, Java, Rust, C++, Kotlin and Swift; frameworks such as Laravel, Rails, Symfony, Flutter, Unity, Godot and Unreal Engine; tools such as Terraform, Maven and Gradle; the editors JetBrains, Visual Studio, VS Code, Vim, Emacs and Sublime Text; and macOS, Windows and Linux. Leave the input empty and run to list them all.
Is this the same as gitignore.io?
It does the same job with a different source. gitignore.io (now at toptal.com) maintains its own template collection; this tool uses github/gitignore, the templates GitHub itself offers when you create a repository. Both are fine; teams that want the file to match what GitHub would give them tend to prefer the latter.
I added a file to .gitignore but Git still tracks it. Why?
.gitignore only affects files Git is not tracking yet. For a file that was committed before, remove it from the index with git rm --cached path/to/file, commit that, and from then on the rule applies. The file stays on your disk.
Is it safe to remove the duplicates?
Yes, with the exception handled for you. A rule listed twice does nothing the second time, unless a negation (a line starting with !) between the two could have re-included some of the same files. The tool keeps the repeat in that case, and when it cannot be sure two wildcard patterns are unrelated it keeps it as well.

The open-source behind it

This tool runs on github/gitignore, released under CC0-1.0. If you need the same behaviour inside your own program, that is the library to reach for.

github/gitignore

Also known as

  • gitignore generator
  • gitignore template
  • create gitignore
  • gitignore node python
  • github gitignore templates
  • gitignore.io alternative