---
title: "gitignore Generator"
description: "Generate a .gitignore from your project folder. Unlike the competition, nothing is uploaded — not even the file names ever leave the page."
url: https://sade.dev/en/tools/gitignore-generator/
lang: en
author: "Muhammet Şafak"
published: 2026-09-23
updated: 2026-09-23
section: Tool
tags: ["git","gitignore","tooling"]
---

# gitignore Generator

> Generate a .gitignore from your project folder. Unlike the competition, nothing is uploaded — not even the file names ever leave the page.

Generates a sectioned, deduplicated `.gitignore` for your project's languages and tools.
Common generators like gitignore.io fetch the template from a server; here templates
ship with the page, and folder selection never leaves the browser either — only file
names are read, never contents.

## Two ways in

- **Pick a folder** — the browser hands over every file's name and relative path inside
  the folder you choose. This tool reads only those names (`file.name`,
  `webkitRelativePath`); no file content is ever read, and `FileReader` is never called
  anywhere in this code. It pre-checks matching templates from the names alone.
- **Pick tags** — without selecting a folder, check as many templates as you want from a
  filterable list. Fully functional on its own, even in a browser that doesn't support
  `webkitdirectory`.

Both paths work together: folder detection pre-checks templates, you correct them.

## Detection rules

- `package.json` → Node.js; if `next.config.js/.mjs/.ts` is also present, Next.js is added.
- `composer.json` → PHP (Composer) and Laravel.
- `Cargo.toml` → Rust.
- `go.mod` → Go.
- `*.xcodeproj` → Xcode.
- `.idea/` → JetBrains IDEs.
- `.DS_Store` → macOS.

Rules stay broad on purpose: a false positive is cheap (you uncheck it), a missed
template is more expensive. You can also check any template by hand.

## Output

Each selected template appears under its own `### Name ###` heading; a line that appears
in more than one template is kept only in the first section it shows up in and dropped
from later ones. Copy the output to your clipboard, use "Copy as command" for a `cat > .gitignore <<'EOF' … EOF` shell command that writes the file under the right
name directly, or download it as a file. The command overwrites an existing `.gitignore`
file. Chrome and other Chromium-based browsers save
the download as `gitignore`, without the leading dot; use the command if you need the
exact name, or rename the downloaded file by hand. The command only works in bash/zsh —
it won't run in Windows cmd or PowerShell.

## Privacy

This tool runs **entirely in your browser** and makes no network requests. When you pick
a folder, the only thing read is file and subfolder names — contents are never read or
sent anywhere. The templates themselves ship with the page too, so nothing is fetched
while generating output.
