# git-secrets

git-secrets is a Secrets Detection product. It runs on-premises. Pricing is free.

Prevents you from committing passwords and other sensitive information to a git repository.

Checked October 2026.

## What is git-secrets?

git-secrets scans commits, commit messages, and --no-ff merges to prevent adding secrets into your git repositories.
If a commit, commit message, or any commit in a --no-ff merge history matches one of your configured prohibited regular expression patterns, then the commit is rejected.

Installing git-secrets

- git-secrets must be placed somewhere in your PATH so that it is picked up by git when running git secrets.

*nix (Linux/macOS)
You can use the install target of the provided Makefile to install git secrets and the man page.
You can customize the install path using the PREFIX and MANPREFIX variables.
make install

Windows
Run the provided install script.

## Where it fits in your security program (NIST CSF 2.0)

- [Protect](https://cybersectools.com/guides/building-protect-program-small-team): helps you prevent attacks and keep data safe.

## Quick facts

- Category: [Application Security](https://cybersectools.com/categories/application-security) · [Secrets Detection](https://cybersectools.com/categories/secrets-detection)
- Deployment: On-Premises
- Company size fit: Startup, SMB, Mid-Market, Enterprise
- Pricing model: Free
- GitHub stars: 12,952
- Website: github.com

## Where it ranks

No shortlist covers this product's category yet. The closest is [Best Application Security Solutions for Business](https://cybersectools.com/shortlists/best-application-security-solutions).

## git-secrets FAQ

### What is git-secrets?

git-secrets is a product in the Secrets Detection category.

### What is the pricing for git-secrets?

git-secrets is free. Download and setup instructions are at https://github.com/awslabs/git-secrets/.

### What are alternatives to git-secrets?

Alternatives to git-secrets listed on CybersecTools:

1. [Checkmarx Secrets Detection](https://cybersectools.com/tools/checkmarx-secrets-detection) - Detects hardcoded secrets in code repos, commits, and containers (Commercial)
2. [Aikido Secrets Detection](https://cybersectools.com/tools/aikido-secrets-detection) - Scans code for exposed API keys, credentials, and tokens in repos and CI/CD. (Commercial)
3. [Datadog Code Security Secret Scanning](https://cybersectools.com/tools/datadog-code-security-secret-scanning) - Scans code repositories and runtime environments for exposed secrets and credentials (Commercial)
4. [Apiiro Secrets Security](https://cybersectools.com/tools/apiiro-secrets-security) - Detects, validates, and remediates secrets in code and pipelines (Commercial)
5. [Cycode Secrets Detection and Scanning](https://cybersectools.com/tools/cycode-secrets-detection-and-scanning) - Scans and detects hardcoded secrets across SDLC and dev tools (Commercial)

Compare all git-secrets alternatives at [https://cybersectools.com/alternatives/git-secrets](https://cybersectools.com/alternatives/git-secrets)

### What deployment and organization size does git-secrets fit?

git-secrets is available as on-premises software. It is listed for startups, small businesses, mid-market companies and enterprises. It is free.

## Compare git-secrets with similar solutions

- [git-secrets vs Checkmarx Secrets Detection](https://cybersectools.com/compare/checkmarx-secrets-detection-vs-git-secrets)
- [git-secrets vs Aikido Secrets Detection](https://cybersectools.com/compare/aikido-secrets-detection-vs-git-secrets)
- [git-secrets vs Datadog Code Security Secret Scanning](https://cybersectools.com/compare/datadog-code-security-secret-scanning-vs-git-secrets)

All alternatives to git-secrets: [/alternatives/git-secrets](https://cybersectools.com/alternatives/git-secrets)

---

Source: https://cybersectools.com/tools/git-secrets

For AI agents: every CybersecTools shortlist is listed at https://cybersectools.com/shortlists.md, and any compare page has a Markdown copy too (add .md to its URL).

More on git-secrets: funding, momentum, hiring and news, plus the full product and company record, are available through the Mandos MCP Server (paid plans), which connects to AI assistants: https://mandos.io/mcp?utm_source=cybersectools.com&utm_medium=product-md
