Skip to content
framework17 active rulesVerified 2026-09-30

NestJS .gitignore Template

NestJS framework dist outputs, coverage reports, and build cache. Generated and merged deterministically with upstream GitHub repository patterns to keep your repository clean of package directories, temporary build artifacts, and local environment files.

Interactive Stack Generator

Preconfigured with NestJS
Search for templates
Quick add:
Selected1
NestJS
Selected Templates (1)
.gitignore
17 rules
### NestJS ###
# Nestjs specific
/dist
/node_modules
/build
/tmp
# Logs
logs
*.log
npm-debug.log*
pnpm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*
# dotenv environment variable files
.env
.env.development
.env.test
.env.production
# temp directory
.temp
.tmp
26 lines•UTF-8
Deterministic

Raw NestJS .gitignore

Crawlable upstream source template
nestjs.gitignore•25 lines•UTF-8
# Nestjs specific
/dist
/node_modules
/build
/tmp
# Logs
logs
*.log
npm-debug.log*
pnpm-debug.log*
yarn-debug.log*
yarn-error.log*
lerna-debug.log*
# dotenv environment variable files
.env
.env.development
.env.test
.env.production
# temp directory
.temp
.tmp

Key Pattern Breakdown

Dependencies & Package Registries

External libraries and package manager directories installed locally rather than stored in version control.

/node_modules

Build Outputs & Compiled Artifacts

Generated binary files, compilation targets, and distribution bundles that can be reliably reproduced from source.

/dist/build

Environment Secrets & Local Overrides

Local environment configurations, secrets, and credentials intended to protect developer-specific settings from exposure.

.env.env.development.env.test.env.production

Execution Caches & Runtime Logs

Diagnostic logs, runtime metadata, test coverage reports, and incremental compiler caches that cause noisy repository diffs.

/tmp*.lognpm-debug.log*pnpm-debug.log*yarn-debug.log*yarn-error.log*+2 more

Source & Verification

License: CC0-1.0

Place this file in the root directory of your project as .gitignore. Changes take effect on newly added or untracked files.