Quality Assurance tools for HTML5
I see more and more people switch over to HTML5 these days, and to help you make sure you did things correctly, there are some tools at your disposal that might be good to know about.
To make sure you didn't misspell any tag or nest elements in a way that is not allowed, or find similar mistakes in your markup, you can use Validator.nu.
Alt text for images
The above-mentioned validator has a feature to help you quality-check your alternative text for your
img elements. Check the Show Image Report checkbox.
You can also disable images in your browser or try to use a text-only browser — the information that the images convey should still be available (but in text form). Sometimes an image doesn't convey any further information than what the surrounding text already says, and in such cases you should use the empty value:
For further advice and examples on how to use the
alt attribute, the HTML 5 spec has lots of information on the topic. If you're not going to read it all, just read the section called General guidelines.
The document outline is the structure of sections in the document, built from the
h6 elements as well as the new sectioning elements (
nav). The document outline is more commonly known as the Table of Contents.
To make sure that you have used the new sectioning elements correctly, you can check that the resulting outline makes sense with the HTML5 Outliner.
If you see "Untitled Section" and didn't expect them, chances are that you should have used
div instead of
If you have a subtitle of a heading that shouldn't be part of the document outline, you should use the
<hgroup> <h1>The World Wide Web Consortium</h1> <h2>Leading the Web to Its Full Potential...</h2> </hgroup>
In this example, only the
h1 will show up in the document outline.
(This only applies to
table elements used for tabular data — not for layout.)
HTML tables have two types of cells: header cells (
th elements) and data cells (
td elements). These cells are associated together in the table: a data cell in the middle of the table can have associated header cells, typically in the first row and/or the first column of the table. To a user who can see, this association seems obvious, but users who cannot see need some help from the computer to understand which cells are associated with which.
You should mark up your header cells with the
th element and check that your cells get associated as you intended using the Table Inspector. If it isn't as you intended, you can consider simplifying or rearranging your table, or you can override the default association using
If you know about other tools for helping with quality assurance of HTML5, or if you have made your own, please share!