Skip to content
Tezmy Tools

.gitignore Generator

Build a .gitignore file for your languages, tools and operating system

Languages, tools and systems
# Node.js
node_modules/
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
.npm
.eslintcache
.env
.env.local
.env.*.local
dist/
build/
coverage/
.next/
.nuxt/
.cache/
*.tgz

# macOS
.DS_Store
.AppleDouble
.LSOverride
._*
.Spotlight-V100
.Trashes

# Visual Studio Code
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
*.code-workspace

Runs in your browser. Nothing is uploaded.

About the .gitignore Generator

.gitignore Generator builds a .gitignore file for your project. Tick the languages and frameworks you use (Node.js, Python, Java, Go, Rust, C and C++, .NET, PHP, Ruby, Swift, Android, Unity, Terraform), the operating systems your team works on (macOS, Windows, Linux) and your editors (JetBrains, Visual Studio Code, Vim), add any lines of your own, and the page combines everything into one tidy file with a heading for each part. It removes lines that appear twice, and you can copy the result or download it as .gitignore.

Updated October 2026

How to use the .gitignore Generator

  1. 1Tick everything that applies to your project and your computer.
  2. 2Add your own lines, such as a secrets file, in the box.
  3. 3Choose whether to remove repeated lines.
  4. 4Read the preview.
  5. 5Copy it or download the .gitignore file and put it in the root of your repository.

What belongs in .gitignore

Ignore everything that can be generated again or that belongs to one person: compiled code, downloaded dependencies, logs, caches, editor settings, operating system files and, above all, secrets. Commit the source, the configuration the team shares and the lock files that pin dependency versions.

Combining templates

Real projects use several tools at once, for example a Node.js front end, a Python back end, macOS laptops and Visual Studio Code. Tick all of them and the page merges them under separate headings. Because several templates share lines such as build/ or .env, the option to remove repeated lines keeps the file short.

  • Language or framework: dependencies and build output
  • Operating system: system files like .DS_Store and Thumbs.db
  • Editor: workspace folders such as .idea and .vscode
  • Custom: secrets, uploads and local data

Keeping it up to date

Review the file when you add a new tool or language. If your team has special files, add them under Custom. Use git status to see what Git still sees, and git check-ignore -v to find out which rule hides a file.

Related tools

Add a licence with the License Generator, write patterns with the Regex Tester, compare files with the Diff Checker and hash files with the Hash Generator. The Chmod Calculator helps with file permissions.

Features

  • Twenty common templates
  • Your own custom lines
  • Headings for each section
  • Repeated lines removed
  • Copy and download
  • Private: nothing is uploaded

Frequently asked questions

What is a .gitignore file?

A text file that tells Git which files and folders to leave out of the repository, such as build output, dependencies, editor settings and secrets.

Where do I put it?

In the root folder of your project, named exactly .gitignore. Git also reads .gitignore files in subfolders.

Why ignore node_modules and similar folders?

They can be rebuilt from your package files, they are huge, and they differ between computers. Keeping them out of Git makes the repository small and fast.

Does .gitignore remove files that are already committed?

No. It only affects files that Git is not yet tracking. To stop tracking a file, run git rm --cached on it and commit.

Should I ignore my .env file?

Yes. Files with passwords and keys must never be committed. If one was committed by mistake, change the secrets and clean the history.

Why ignore operating system and editor files?

Files such as .DS_Store and .idea are specific to one person's machine and just add noise for the team. Some teams put them in a global ignore file instead.

What does a leading slash or a trailing slash mean?

A trailing slash matches only folders, and a leading slash anchors the pattern to the folder of the .gitignore file. A line starting with ! re-includes something.

Is my list uploaded?

No. The file is built in your browser.

Related tools