Check URLs for broken links. Scan individual URLs, files containing links, or crawl websites. Generates reports with HTTP status codes.
| Command | Description |
|---|---|
| --------- | ------------- |
check | Check a single URL — shows HTTP status, redirect target if applicable |
scan | Extract and check all URLs found in a text file |
site | Crawl a webpage, extract all href/src links, and check each one |
report | Generate a timestamped report file from all URLs in a text file |
# Check a single URL
deadlink check https://example.com/page
# → 200 OK
# Scan a markdown file for broken links
deadlink scan README.md
# → Extracts all http/https URLs and checks each one
# Crawl a website
deadlink site https://example.com 1
# → Fetches the page, extracts all links, checks each
# Generate a report file
deadlink report bookmarks.html
# → Creates deadlink-report-20240101-120000.txt
curl — must be installed and in PATHhttp:// and https:// linkssite command does basic HTML link extraction (href and src attributes)共 2 个版本