Skip to content
OSINTtools.io

Gitleaks

Verified yesterday

Open-source scanner that finds hard-coded secrets such as API keys and tokens in Git history, directories and stdin.

Go CLI (Windows, macOS, Linux) · Docker · Open source · Infrastructure and domains · gitleaks.io

Takes
URL · File
Pricing
Free, open source
Footprint
Passive · no contact with target
Account
Not needed
API
No public API
Last verified
Nov 27, 2026
Summary

Open-source scanner that finds hard-coded secrets such as API keys and tokens in Git history, directories and stdin. It takes URL and file. Read the cons before you build a workflow on it.

What it does

Gitleaks is a command-line tool that scans Git repositories, folders and piped input for secrets like API keys, passwords and tokens. It ships with a large set of detection rules, can decode encoded strings before matching, supports custom rules in a TOML config, and writes reports in JSON and other formats.

Investigators and security researchers run it over a cloned public repository to see whether an organisation has exposed credentials or internal endpoints in its code or commit history. Findings show where a secret is and should be reported responsibly, not used.

Footprint is passive: it reads its own index or third-party records and does not contact the target. No account is needed. There is no public API.

Pros
  • +Fast single binary
  • +Widely used and actively maintained
  • +Very configurable rules
  • +Free and open source
Cons
  • −Pattern matching produces false positives
  • −Does not check whether a found secret is live
  • −Built for code security, so OSINT use needs care and a lawful basis

When to use it

  1. 01Use it when you want to check a public repository's history for exposed keys or internal URLs.
  2. 02Use it when you need to audit your own code before publishing it.
Key featuresScans full Git historyDirectory and stdin scanningBuilt-in secret detection rulesCustom TOML rules and allowlistsDecoding of base64, hex and percent-encoded valuesJSON, CSV and template reportsPre-commit and CI use

Next steps from this result

Suggested from the inputs Gitleaks takes
  • Found a resultConfirm it with a second, independent source before you record it
  • Found a new identifierPivot on it only if your scope covers the new target
    Depends

Quick start

Homebrew or Docker
brew install gitleaks
gitleaks git -v path_to_repo
gitleaks dir -v path_to_directory_or_file

Technical details

Listing verified by an editor on Nov 27, 2026
API
No public API
Account
Not needed
Footprint
Passive · no contact with target
Pricing
Free, open source
Platforms
Go CLI (Windows, macOS, Linux) · Docker
Repository
gitleaks/gitleaks 31,378 stars
Language
Go
Licence
MIT
Last commit
Oct 2026
Listed
Nov 27

Reviews

No reviews yet

Written by signed-in members. Each review appears here after an editor has read it.

Used Gitleaks? Sign in to say what you used it for and how it went.

Sign in to review

Alternatives to Gitleaks

Listed tools that take the same inputs, closest match first.

GitleaksOpen source · verified yesterday
Visit gitleaks.io (opens in new tab)