Gitignore Generator
Tick the languages, tools and systems you use. The tool combines their ignore patterns into one .gitignore file you can copy.
Use the tool
Loading the tool…
About Gitignore Generator
Build a .gitignore file, which tells Git which files and folders to leave out of a project. You can add a comment above each section, so the file is easy to read.
Worked example
Turn on the comments option and generate the file. Each section of the list has a comment above it.
Limits
A .gitignore file only affects files that Git has not yet tracked. Check that the file leaves out no files your project needs.
How to use Gitignore Generator
- Tick the templates that match your project.
- Choose whether sections get a comment.
- Copy the result.
- Save it as .gitignore in the top folder of your project.
Good to know
- Files that Git already tracks stay tracked. Remove them with git rm --cached first.
- Review the patterns, because some projects need to keep files such as lock files.
- A line starting with ! makes an exception to an earlier pattern.
- The patterns are a starting point and not a full copy of any official template.
Frequently asked questions
Where do I put the file?
Save it as .gitignore in the main folder of your repository.
Why is a file still tracked?
Git keeps tracking a file it already knows about. Run git rm --cached on it.
Is anything saved or sent?
The work happens in your browser on this page, and nothing is stored or sent to us.