CLI that checks a website before launch: broken links, HTTPS, redirects, title, meta, sitemap
356
A small command line tool that checks a website before launch and prints a clear, plain report:
broken internal links, HTTPS and HSTS, the http and www redirects, page title, meta description,
mobile viewport, a noindex left over from staging, robots.txt, XML sitemap and an old copyright
year in the footer.
Source code, issues and full documentation: github.com/digitalcaveuk/site-preflight (MIT licence). Tool page and guide: digitalcave.uk/tools/site-preflight.
Build the image straight from the GitHub repository, then run it:
docker build -t site-preflight https://github.com/digitalcaveuk/site-preflight.git
docker run --rm site-preflight --url https://example.com
Or without Docker: pip install git+https://github.com/digitalcaveuk/site-preflight
| Option | Meaning |
|---|---|
--url | the site to check (example.com works too, https is assumed) |
--max-links N | how many internal links from the home page to test (default 25, 0 skips the link check) |
--timeout S | seconds to wait for each request (default 10) |
--json | print the full report as JSON instead of text |
The exit code is 1 if any check failed and 0 otherwise, so it fits in a CI pipeline or a deploy script.
$ docker run --rm site-preflight --url example.com
site-preflight 0.1.0 https://example.com/
checked at 2026-11-25T13:05:37Z
[PASS] Home page HTTP 200
[PASS] HTTPS served over https
[WARN] HSTS header no Strict-Transport-Security header
[FAIL] http:// to https:// http://example.com/ does not redirect to https (status 200)
[WARN] www / non-www https://www.example.com/ serves a page but does not redirect to example.com (duplicate content)
[PASS] Page title 14 characters: Example Domain
[FAIL] Meta description missing
[PASS] Mobile viewport width=device-width,initial-scale=1
[PASS] Indexable no noindex in meta robots or X-Robots-Tag
[WARN] robots.txt not found (status 404)
[WARN] XML sitemap no sitemap found at robots.txt, /sitemap.xml or /sitemap_index.xml
[INFO] Copyright year no copyright notice found (or it is added by JavaScript)
[INFO] Internal links no internal links found on the home page
5 passed, 4 warnings, 2 failed, 2 info
Not ready: fix the FAIL items before launch.
| Check | What passes |
|---|---|
| Home page | returns HTTP 2xx (redirects are followed and shown) |
| Internal links | up to --max-links links from the home page return 2xx or 3xx |
| HTTPS / HSTS | served over https with a Strict-Transport-Security header |
| Redirects | http:// and the www or bare variant redirect permanently to the main URL |
| Title / meta description | present and a sensible length |
| Mobile viewport | width=device-width viewport meta is present |
| Indexable | no noindex in meta robots or the X-Robots-Tag header |
| robots.txt / sitemap | robots.txt exists and a sitemap is found |
| Copyright year | the footer shows the current year |
Built by DigitalCave, an all-in-one web design, SEO and digital marketing agency. If you need a site built properly from the start, see our web design service in Birmingham.
Author: DigitalCave (Rocky V).
Content type
Image
Digest
sha256:4236cbfd3…
Size
21.5 MB
Last updated
5 days ago
docker pull digitalcave/site-preflight