Use this HTML validation and accessibility debugging checklist to find structural errors, semantic problems, and keyboard barriers before a production page ships. The workflow combines an HTML validator, browser inspection, manual interaction, and assistive-technology checks so teams can repeat it for templates, components, and content changes.
Overview
Valid HTML is not automatically accessible, and a page can appear correct in a visual browser while still failing for keyboard users, screen-reader users, or people who rely on zoom and other input methods. Treat validation as two connected reviews: first confirm that the document is structurally sound, then confirm that its meaning and interaction model are usable.
Start with the rendered page rather than only a source file. Server-side templates, client-side rendering, CMS fields, injected widgets, and browser error recovery can change the final document. Save a representative URL or local build for each review, record the viewport and browser used, and note whether the page requires authentication or JavaScript.
An HTML validator is useful for detecting malformed syntax, duplicate attributes, missing required relationships, and invalid nesting. It is not a complete accessibility test. Pair it with browser developer tools, keyboard-only navigation, a screen reader or other assistive technology, zoom testing, and focused checks of forms, links, images, headings, and landmarks.
What to track
1. Document structure and valid nesting
Check that the document has a clear html, head, and body structure, a meaningful title, an appropriate language declaration such as lang, and a logical character encoding declaration. Review validator output after the page has fully rendered.
Pay special attention to invalid nesting. A common example is placing block-level page structure or interactive controls inside elements that do not permit them. Broken nesting can cause the browser to rearrange the DOM, which may change reading order, styling, form behavior, or keyboard navigation. Fix the underlying markup instead of suppressing the warning with CSS or JavaScript.
2. Semantic elements and landmarks
Use elements according to their meaning. Prefer header, nav, main, aside, and footer for page regions; use article and section when they represent meaningful content groups. A landmark should help a user understand or navigate the page, not merely reproduce every visual container.
Confirm that the page has one clear primary content area and that navigation regions have useful accessible names when more than one exists. Use native controls such as button, a, input, and select before building custom controls from generic elements. Native semantics provide a stronger starting point for keyboard and assistive-technology support.
3. Headings and reading order
Review headings as an outline of the page, not as a way to style text. The main topic should be identifiable, subsections should describe the content that follows, and heading text should remain meaningful when read without surrounding visual design. Avoid choosing a heading level only because its default font size looks right; use CSS for presentation.
Use browser inspection and keyboard navigation to compare visual order with DOM order. A layout that looks correct because of grid or flexbox placement can still be read in a confusing sequence if the source order does not match the intended experience.
4. Images, links, and text alternatives
For each informative image, provide concise alternative text that communicates its purpose in context. Decorative images generally need an empty alternative so they are not announced as content. An image used as a link or button needs text that describes the destination or action, not only the subject of the picture.
Review links without relying on color or surrounding layout. Link text should identify the destination or action, and repeated links should be distinguishable when their destinations differ. Check that visited, hover, focus, and disabled-looking states are not the only way to understand a control.
5. Forms and error handling
Every form control needs a programmatically associated label or an equivalent accessible name. Group related choices with an appropriate grouping mechanism, preserve instructions near the relevant control, and make required fields and constraints understandable in text rather than color alone.
Trigger validation errors intentionally during testing. Confirm that the error is associated with the affected field, explains how to correct it, and can be discovered without searching the page. Test keyboard submission and server responses as well as client-side validation. For deeper form troubleshooting, see the HTML Form Debugging Guide.
6. Keyboard focus and interaction
Unplug the mouse and move through the entire page with the keyboard. Focus should be visible, follow a sensible order, and never become trapped in a modal, menu, carousel, or custom widget. All actions available by pointer should have a keyboard path, including opening controls, closing overlays, changing tabs, submitting forms, and dismissing messages.
Check focus after dynamic updates. If a dialog opens, focus should move to a useful location and return sensibly when it closes. If a form error or status message appears, the user should have a practical way to discover it. Do not remove the browser's focus indicator without providing an equally clear replacement.
HTML element reference
| Element or pattern | Use it for | Review point |
|---|---|---|
a | Navigation to another URL or document location | Has a meaningful accessible name and destination |
button | An action on the current page | Can be focused, activated, and named clearly |
label | Visible text for a form control | Is programmatically associated with the control |
img | Embedded image content | Alternative text matches the image's purpose |
nav | A major group of navigation links | Multiple navigation regions are distinguishable |
main | The page's primary content | There is a clear, non-duplicated main region |
h1–h6 | Content hierarchy | Levels and wording reflect the actual structure |
dialog or a dialog pattern | Focused temporary interaction | Opening, focus, naming, escape behavior, and return focus work |
7. Responsive and visual checks
Test narrow and wide layouts, zoom, increased text size where supported, reduced motion preferences, and high-contrast or forced-color scenarios where relevant to your audience. Look for clipped text, overlapping controls, horizontal scrolling, insufficient focus visibility, and content that becomes unavailable when styles or scripts fail.
Cadence and checkpoints
Run the full checklist before a new page template, shared component, major content migration, or production release. For established pages, use a lighter monthly or quarterly review based on change frequency and risk. Recheck high-traffic forms, authentication flows, checkout-like tasks, and pages that receive frequent CMS edits more often than stable informational pages.
- Build checkpoint: run automated HTML and accessibility checks against the generated document, not only the component source.
- Browser checkpoint: inspect the DOM, landmarks, heading structure, form names, console output, and focus behavior in supported browsers.
- Manual checkpoint: complete the key task with a keyboard, zoom the page, resize the viewport, and test error and empty states.
- Assistive-technology checkpoint: sample important flows with a screen reader or other relevant assistive technology. Listen for names, roles, states, reading order, and status changes.
- Regression checkpoint: compare results with the previous release and record unresolved issues, affected URLs, owner, severity, and retest date.
Keep validator output with the build or review record. A clean result is useful evidence, but it should not be treated as an accessibility approval by itself. For broader browser and device coverage, use the Cross-Browser HTML Testing Checklist.
How to interpret changes
Prioritize defects by user impact and task risk rather than by the number of warnings. The following matrix provides a practical starting point:
| Priority | Typical issue | Recommended response |
|---|---|---|
| Critical | Keyboard trap, inaccessible primary action, unusable authentication or form error flow | Block release until a usable path is verified |
| High | Missing form labels, broken reading order, absent main content, misleading link names | Fix before release or document an explicit, time-bound exception |
| Medium | Weak heading hierarchy, unclear repeated links, inconsistent focus styling | Schedule for the current component or content iteration |
| Low | Minor validator warning with no observed user impact or a nonessential markup cleanup | Track and address during routine maintenance |
When a validator reports an error, reproduce it in the rendered DOM and identify the component or content source responsible. One template defect may create hundreds of page errors, while a single CMS entry may affect only one URL. After fixing it, test both the original case and a nearby edge case, such as a long label, missing image, empty result, or translated string.
Separate structural failures from content decisions. Invalid nesting is generally a markup defect; vague alternative text may require product or editorial context. Record both the technical cause and the user-facing effect so future reviewers can recognize regressions quickly.
When to revisit
Revisit this checklist whenever HTML templates, design-system components, JavaScript widgets, routing, forms, or content models change. It is also worth repeating after a CMS migration, analytics or consent integration, authentication update, localization pass, major browser-support change, or a redesign that alters focus order or responsive behavior.
Use a monthly or quarterly checkpoint for recurring monitoring. At each review, select representative page types rather than checking only the home page: a listing, detail page, form, error page, authenticated view, modal workflow, and any page with user-generated content. Refresh the test set when new components or interaction patterns are introduced.
Before closing a review, complete this reusable pre-release list:
- Run an HTML validator on the final rendered document and resolve actionable errors.
- Confirm document language, title, landmarks, heading order, and DOM reading order.
- Check accessible names and states for links, buttons, images, inputs, menus, dialogs, and status messages.
- Complete the primary task with keyboard-only navigation and verify visible focus.
- Trigger validation, empty, loading, success, and failure states.
- Test responsive layouts, zoom, text expansion, and relevant motion or contrast preferences.
- Sample key flows with assistive technology and record the browser and setup used.
- Log each defect with severity, affected component or URL, owner, fix, and retest result.
Keep the checklist alongside the release or component documentation, then update it when your interface gains a new interaction pattern. For pages that render user-provided text, pair accessibility review with safe output handling using the HTML Escaping and XSS Prevention guide. A repeatable review process makes HTML validation and accessibility testing part of ordinary debugging rather than a final-stage surprise.