SSC, the static site checker, is an opinionated HTML nit–picker. It’s a command line tool intended for people, like me, who hand code websites, to identify coding issues that should perhaps be addressed. Point it to a directory containing your website’s HTML / XHTML / SHTML, and it will analyse what’s there.
- HTML tags / 1.0 / + / 2.0 / 3.0 / 3.2 / 4.00 / 4.01 / 5.0 / 5.1 / 5.2 / 5.3 draft / WhatWG living standards (January 2005 to January 2021)
- XHTML 1.0 / 1.1 / 2.0,
- SVG 1.0 / 1.1,
- MathML 1 / 2 / 3,
- site internal broken links,
- external broken links (requires curl),
- simple server side includes,
- schema.org microdata 2.x / 3.x / 4.0 / 5.0 / 6.0 / 7.x / 8.0 / 9.0 / 10.0 / 11.0 / 12.0 (living standard semantics), &
- microformats v1 / v2.
It is incomplete. In particular, it does NOT:
- process styles, except grabbing class names from CSS;
- comprehend XML or any derivative beyond those noted above;
- suss SVG 1.2 or 2 (yet);
- ken MathML 4 (yet);
- consider XHTML 5.0 (yet);
- behave in an even vaguely secure manner (its parsers are holier than the infamous cow), nor
- do what you want or expect.
It can produce:
- a detailed list of matters to consider,
- site statistics,
- ‘repaired’ code, &
- a deduplicated version of the site.
It compares to the following products:
- HTML Tidy can convert between HTML and XHTML, but checks few attributes and spots no broken links;
- Linkchecker takes orders of magnitude longer to scan a large site, and can forget to mention many broken links;
- various HTML linters that analyse individual files, but not complete sites.
Read more about SSC:
Here’s a short example of ssc’s output, with added comments:
*** 404.html 9: <a href="/news"> ==> "/news" not found <!-- there is no file or directory called /news --> 50: <link href="http://purl.org/dc/elements/1.1/" rel="schema.dc"> ..> <LINK> REL="schema.dc" is not standard HTML5/20210101/SVG-2.0/MathML-3/WhatWG <!-- schema.dc is not a standard rel value (it’s part of Dublin Core) --> 75: <span class="biggerscreen"> ==> <span> has no matching </span> --> "biggerscreen" is unknown <!-- although </SPAN> is not required, forgotten closures make HTML inefficient --> <!-- the CSS style biggerscreen has not been defined --> 86: </nav> --> inserted missing </span> <!-- and this is where the forgotten </SPAN> matters -->
If you would like to see more output, grab the project, compile it, and then run either recipe/tea/fulltest.sh (various unii) or recipe/tea/fulltest.bat (windows). It’ll output many examples to recipe/out.