{{ summaryTitle }}
{{ summaryValue }}

{{ summaryLine }}

{{ badge.label }} {{ badge.value }}
{{ summaryAnnouncement }}
HTML validation source and review controls
Paste one source or load one HTML/text file up to 200 KB. The included sample deliberately contains several findings.
{{ sourceMeta }}
{{ fileStatus || 'Drop one HTML or text file onto the editor. No source leaves this browser.' }}
Pin Document or Fragment when the source context is known; Auto detect reports its resolved context in every result.
Choose Strict review when heading sequence and image alternative-text signals belong in this pass.
Neutral when blank. Enter a known document-language context only when you want a mismatch finding.
The neutral default keeps the ledger compact. Enable this when exact source context should travel with copied or downloaded rows.
{{ include_excerpts ? 'Enabled' : 'Disabled' }}
{{ include_excerpts ? 'Included' : 'Omitted' }}
Supported HTML findings ordered by source location and rule id
LocationRuleSeverityFindingWhat to doCopy
L{{ finding.line }}:C{{ finding.column }}<{{ finding.element }}> {{ finding.rule }}{{ finding.category }} {{ finding.severity }} {{ finding.title }}{{ finding.message }}{{ finding.excerpt }} {{ finding.guidance }}
{{ tableExportStatus }}
{{ chartExportStatus }}

The chart renderer is unavailable. Counts remain available in the summary and finding ledger.

Repair plan
{{ group.title }}
{{ group.count }} {{ group.count === 1 ? 'finding' : 'findings' }}
  1. {{ item.rule }} at L{{ item.line }}:C{{ item.column }}: {{ item.guidance }}

No repair action is required by the supported rules in this pass.

Scope boundary

This local ruleset preserves the source and does not certify rendering, accessibility, links, security, browser compatibility, or complete HTML conformance. Use a full conformance checker and browser/accessibility testing before release.

HTML browsers recover from many authoring mistakes instead of stopping at the first bad tag. A missing end tag may be inferred, a stray closing tag may be ignored, and a repeated attribute may lose one of its values. The page can still look reasonable while the browser has built a document tree different from the one the author intended.

Validation makes that recovery visible before it turns into broken labels, duplicate fragment links, unreliable scripts, or inconsistent table relationships. It also separates complete documents from fragments. A document normally needs a doctype, title, and primary language; a fragment copied from a template or component does not own those page-level requirements.

Document
A complete HTML resource with page-level structure and metadata, including the short HTML doctype.
Fragment
A piece of markup intended to be inserted into another document, such as a component example or server-rendered partial.
Parse recovery
The browser rules that continue parsing after malformed or omitted markup. Recovery can preserve a visible page while changing element nesting.
Conformance finding
A source-level problem such as a duplicate identifier, invalid label target, or disallowed table-header reference.

Not every authoring concern has the same certainty. Duplicate id values and a label that points to no labelable control are concrete defects. Heading jumps and missing image alternative text need more context, so they belong in a stricter review pass rather than the base result. An image may have a documented narrow exception, and a heading sequence can be deliberate in specialized content.

Markup validation is still only one part of web quality. It cannot decide whether CSS renders correctly, a link resolves, JavaScript behaves safely, form instructions are understandable, or an accessibility tree supports the intended task. Those questions need browser inspection, accessibility testing, link checks, and project-specific review after source findings are cleared.

Treat a clean HTML report as evidence that the supported source rules passed. It is not a browser, sanitizer, security scanner, accessibility audit, or universal conformance certificate.

How to Use This Tool:

Identify the source as a complete document or fragment before judging page-level findings.

  1. Paste markup into HTML source or load one local HTML or text file no larger than 200 KB.
  2. Set Mode to Document or Fragment when the context is known. Auto detect chooses Document when it sees an HTML doctype or an html, head, or body element; otherwise it chooses Fragment.
  3. Use Recommended for syntax, recovery, identifiers, forms, tables, entities, and document metadata. Choose Strict review when heading order, repeated top-level headings, and missing image alt attributes should also be raised for judgment.
  4. Enter Expected language only when the surrounding page or publishing workflow declares one. A value such as en, en-US, or zh-Hant can reveal a mismatch with the document lang value.
  5. Fix errors from the earliest source location first, then validate again. Turn on source excerpts only when copied or downloaded finding rows need the affected line for review.

Interpreting Results:

Errors identify supported syntax, recovery, or conformance problems. Repair malformed tags, duplicate attributes, mismatched nesting, duplicate identifiers, invalid label or table references, and invalid character references before relying on later warnings.

Warnings ask for context. A missing document title or language needs author attention, while strict-review heading and image signals need a deliberate content or accessibility decision. The resolved mode and review profile belong with the result because the same fragment can produce different page-level findings when treated as a document.

No findings does not mean the page is accessible, secure, fully conforming, or compatible with every browser. Render the source in its real application, test keyboard and assistive-technology behavior, follow links, and run the project's own build and policy checks before release.

Technical Details:

HTML parsing is not XML parsing. Some end tags may be omitted, void elements never have end tags, raw-text elements contain text that must not be scanned as ordinary markup, and specific start tags implicitly close an open element. Bounded analysis must model these distinctions before it can report a stray or unclosed tag without flooding the result with false positives.

Rule Core

The rule order moves from source bounds and tokenization into element relationships, then adds document-only and strict-review checks. Findings retain original line and column locations even when parser recovery closes an element implicitly.

HTML validation rule groups
Rule group Checks Applies to
Token and tag structureComments, declarations, malformed tags, duplicate attributes, stray end tags, void-element endings, recovery closures, and required end tagsEvery mode
IdentifiersNon-empty id values without whitespace and uniqueness across the submitted sourceEvery mode
Forms and tableslabel for resolves to one non-hidden labelable element; headers resolves to unique th identifiers; scope uses a defined keywordEvery mode
Character referencesNumeric references use valid scalar values and semicolons; core named references include their semicolonsEvery mode
Document metadataOne short HTML doctype, one non-empty title, and a valid primary language when declaredDocument mode
Language contextThe document language equals the expected tag or begins with that tag plus a subtagDocument mode when an expected language is supplied
Strict reviewSkipped heading levels, more than one h1, and images without an alt attributeStrict review profile

Auto detection is intentionally simple and deterministic. After comments are ignored, an HTML doctype or explicit html, head, or body element resolves the source as a document. Other source resolves as a fragment. Pinning the mode avoids accidental changes when a snippet gains one of those page-level tokens.

Language tags are checked against a bounded BCP 47 syntax pattern, including recognized grandfathered and private-use forms. The check does not consult the live language-subtag registry. When an expected language is present, en-US matches expected en, but expected en-US does not match an actual en because the document is less specific than the requested context.

HTML analysis limits
Limit Maximum Result behavior
Unicode characters200,000Larger source is rejected.
Lines5,000Larger source is rejected.
Tokens20,000Analysis stops at the boundary and reports truncation.
Open-element depth256Deeper nesting reaches the analysis boundary.
Attributes on one tag100Later attributes are not analyzed.
Reported findings200Only the earliest ordered findings are returned.

The submitted markup remains inert. Scripts are not executed, resources are not fetched, CSS and SVG are not validated, and the source is not repaired or reformatted. Those exclusions protect the meaning of the report: it describes the supported HTML source rules only.

Limitations:

A bounded source review cannot replace a full conformance checker or a rendered test. It does not evaluate content models comprehensively, follow links, resolve custom elements, inspect framework templates, execute scripts, calculate accessible names, or certify assistive-technology support.

  • Use a standards-grade HTML checker when complete conformance coverage is required.
  • Use browser developer tools and automated accessibility checks for the rendered document, followed by keyboard and assistive-technology testing for important flows.
  • Validate generated HTML after templates render; a clean template fragment does not prove that its assembled document is clean.

References: