CLI tool that finds broken or dead links on a web page. Give it a URL; it crawls the site recursively (same-domain), checks discovered links, and reports dead links (4xx/5xx, soft 404s) and links that block the scraper (403).
macOS / Linux (one-liner):
curl -fsSL https://raw.githubusercontent.com/shutterscripter/deadsniper/main/install.sh | shAdd to PATH if prompted (e.g. in ~/.zshrc or ~/.bashrc):
export PATH="$PATH:$HOME/.local/bin"Then run:
deadsniper -u https://example.comWindows: Download the latest deadsniper-windows-amd64.exe from Releases, then:
.\deadsniper-windows-amd64.exe -u https://example.com| Platform | Install |
|---|---|
| macOS (Intel) | One-liner above, or Releases → deadsniper-darwin-amd64 |
| macOS (Apple Silicon) | One-liner above, or Releases → deadsniper-darwin-arm64 |
| Linux (amd64/arm64) | One-liner above, or Releases → deadsniper-linux-amd64 / deadsniper-linux-arm64 |
| Windows (amd64/arm64) | Releases → deadsniper-windows-amd64.exe / deadsniper-windows-arm64.exe |
deadsniper -u <URL>Examples:
deadsniper -u https://example.com
deadsniper --url https://mysite.com/page.html
deadsniper -u https://example.com --recursive --max-depth 5
deadsniper -u https://example.com -r=false
deadsniper --version# Default recursive crawl (same-domain), depth 3
deadsniper -u https://example.com
# Recursive crawl with custom depth
deadsniper -u https://example.com --recursive --max-depth 5
# Short flags
deadsniper -u https://example.com -r -m 5
# Disable recursion (single page only)
deadsniper -u https://example.com -r=false| Flag | Short | Description | Default |
|---|---|---|---|
--url |
-u |
URL of the page to check for dead links | (required) |
--verbose |
-v |
Verbose output | false |
--threads |
-t |
Number of threads | 1 |
--delay |
-d |
Delay between requests (seconds) | 0.5 |
--timeout |
-T |
Request timeout (seconds) | 10 |
--output-type |
-o |
Output: 1=text file, 2=json file | 1 |
--recursive |
-r |
Recursively crawl same-domain pages | true |
--max-depth |
-m |
Max recursion depth for page crawling | 3 |
--help |
-h |
Help | |
--version |
Print version |
- Dead links — URLs that returned 4xx/5xx or a “soft 404” (HTTP 200 but page says not found).
- Blocked (403) — URLs that returned 403 (server blocks the scraper; may work in a browser).
With --output-type:
-o 1: write dead links todata.txt-o 2: write dead links todata.json
- Fetches the URL with a browser-like User-Agent.
- Parses HTML and collects
<a href="...">links recursively on same-domain pages (up to--max-depth). - Requests each link and classifies: dead (4xx/5xx or soft 404), blocked (403), or OK (200/301/302/304).
Single platform:
go build -o deadsniper .
# Or: go build -o $(go env GOPATH)/bin/deadsniper .All platforms (local):
chmod +x build.sh
./build.shBinaries go to dist/. Requires Go 1.23+.
git tag v0.1.4
git push origin v0.1.4See LICENSE in the repository.