Read Me Page
Validate WCAG, Section 508, HTML, CSS, Links, and Spelling

HTML errors

Errors due to non-conformance with the chosen HTML specification

Code
Summary
Details
This element is not recognised
This error is often raised when an old element has been used when validating against a newer HTML specification. Alternatively you may have misspelled the name.
This tag should not be nested within any other tags
This issue is normally due to other errors within the page, such as using a frame set with the wrong <!DOCTYPE> tag. You can find a list of the <!DOCTYPE> tags that Total Validator recognises here.
This should be the first HTML tag or content in the file
The <!DOCTYPE> tag should appear before all other HTML tags or non-whitespace content (with XHTML it may appear after the XML declaration).
An end tag is not allowed for this element
This issue occurs when you use an end tag where no end tag is allowed according to the HTML specification being validated against. Correcting this issue is normally a matter of deleting the end tag indicated.
The matching end tag appears to be missing
According to the HTML specification being validated against, the tag must have an end tag. Sometimes this error is caused by improperly nested tags where the end tag exists but cannot be matched with the corresponding start tag.
This tag or content must be nested within another tag
The tag or content appears at the top level, but it must be nested inside another tag. This error is typically caused by missing or misplaced <html>, <head> and <body> start and end tags. Although these tags are normally optional in HTML, it is poor practice to miss them off and often causes problems for search engine robots.
This tag or content must be nested within another tag
The tag or content appears at the top level, but it must be nested inside another tag. This error is typically caused by missing or misplaced <html>, <head> and <body> start and end tags. Although these three tags are actually optional in HTML, it is poor practice to miss them off and often causes problems for search engine robots.
There must be a <!DOCTYPE> tag at the top of the page (if 'auto-detecting' then a best-fit <!DOCTYPE> will be used)
A <!DOCTYPE> tag should be placed before any other HTML tag or non-whitespace characters on the page. Sometimes the <!DOCTYPE> tag is in the wrong place, but is usually missing altogether in these cases. A correct <!DOCTYPE> tag is needed to ensure that the browser interprets the HTML correctly. You can find a list of the <!DOCTYPE> tags that Total Validator recognises here.
This tag or content is not allowed here. One of the following was expected: LIST OF VALID TYPES/TAGS
There are strict rules as to what tags may be nested within others, as well as the order and number of tags allowed. If this error is preceded by an E604 error (missing end tag) then correcting the earlier E604 error may correct this one. Otherwise either remove the item marked or nest it within one of the types or tags listed.
One or more of the following tags are missing from within the enclosing tag: LIST OF MISSING TAGS
The HTML specification being tested against defines that the tag identified must have one or more specific tags nested within it. You should add one or more of the missing tag(s) as appropriate.
Only one of this type of tag should be used within the enclosing tag
This error occurs when the specification only allows one of a certain tag to be nested within the enclosing tag, and more than one tag was found.
This tag or content is not allowed here
Each tag is defined by the HTML specification as only being allowed to contain certain other items nested within it, and sometimes these nested items may only appear once or only in a certain order. A common problem is to use a tag where it may not be obvious that it is not allowed, and may be accepted by many browsers. Try removing the offending item or replacing it.
The <!DOCTYPE> tag does not match the HTML specification being checked against
The <!DOCTYPE> tag should exactly match the one that uniquely identifies the specification being tested. You can find a list of the <!DOCTYPE> tags that Total Validator recognises here.
The 'ATTRIBUTE NAME' attribute is not allowed here
The most common reasons for this error are the use of a old unsupported attribute, a new one which is not yet part of the specification being tested against, or the misuse of attributes for use with javascript. If the attribute is for use with AngularJS, then see the FAQ for more information.
The 'ATTRIBUTE NAME' attribute for this tag is missing
The HTML specification being validated against requires that the attribute indicated must be used.
The 'ATTRIBUTE NAME' attribute does not have a valid value: LIST OF VALID VALUES
The HTML specification being validated against defines certain valid values for each attribute. Usually a list of valid values will be displayed when you see this message. Note that many values must be in lower case in XHTML, including the 'x' in numeric hex entity references. Also note that what values are allowed varies from standard to standard.
The values of all attributes must be enclosed by quotes
In XHTML all attribute values must be enclosed by quotes. See https://www.w3.org/TR/xhtml1/#h-4.4 (displayed in new window). This error is sometimes caused by a badly formatted tag possibly with single or double quotes in the wrong place or mismatched. Check that there are no extra or missing quote characters.
The 'content' attribute should have a value of 'application/xhtml+xml' for XHTML
Note that <meta> tags override HTTP headers and XHTML should be served with a content type of 'application/xhtml+xml', but the content type used was not recognised. See https://www.w3.org/TR/2009/NOTE-xhtml-media-types-20090116/#media-types (displayed in new window).
The 'content' attribute should have a value of 'text/html' for HTML
Note that <meta> tags override HTTP headers and HTML should be served with a content type of 'text/html'. See https://www.w3.org/TR/2009/NOTE-xhtml-media-types-20090116/#media-types (displayed in new window).
All element names must be in lower case
XML is case-sensitive and in XHTML all element names are defined as being in lower case. See https://www.w3.org/TR/xhtml1/#h-4.2 (displayed in new window).
All attribute names must be in lower case
XML is case-sensitive and in XHTML all attribute names are defined as being in lower case. See https://www.w3.org/TR/xhtml1/#h-4.2 (displayed in new window).
Self-closing tags are not allowed in HTML 1-4
In older versions of HTML you are not allowed to end a tag with the '/' character. This is only valid with HTML5 and XHTML documents.
The name and id attributes must have the same value
When id and name attributes appear in the same element they must have the same value. See https://www.w3.org/TR/html401/struct/links.html#h-12.2.3 (displayed in new window).
Anchor name and id attributes must be unique in the same document. See matching tag(s) on line(s): LINE_NUMBERS
All id and anchor name attributes in the same document must have unique values. See https://www.w3.org/TR/dom/#concept-id (displayed in new window), and https://www.w3.org/TR/html401/struct/links.html#h-12.2.3 (displayed in new window).
The 'content-type' http header should have a value of 'application/xhtml+xml' for XHTML
XHTML should be served with a content type of 'application/xhtml+xml', but the content type used was not recognised. See https://www.w3.org/TR/2009/NOTE-xhtml-media-types-20090116/#media-types (displayed in new window).
The 'content-type' http header should have a value of 'text/html' for HTML
HTML should be served with a content type of 'text/html'. See https://www.w3.org/TR/2009/NOTE-xhtml-media-types-20090116/#media-types (displayed in new window).
The XML declaration must appear before any other content or tags
The XML declaration (if supplied) must be the first thing in the file, before any other content or tags.
Only one XML declaration is allowed
Only one XML declaration may be supplied and this must be the first thing in the file, before any other content or tags.
The XML declaration must contain a 'version' attribute
The XML declaration must contain a 'version' attribute. Check the spelling of any attributes supplied.
Invalid value for the 'version' attribute
The 'version' attribute must be set to the string '1.0'.
Invalid value for the 'encoding' attribute
The 'encoding' attribute must begin with a letter [a-zA-Z] and may be followed by any number of letters, digits [0-9], hyphens, underscores, and periods.
Invalid value for the 'standalone' attribute
The 'standalone' attribute must be set to either 'yes' or 'no'.
Unknown or invalid attribute
The XML declaration contains an unrecognised or invalid attribute. Check for spelling mistakes.
The root element name 'html' is missing from the <!DOCTYPE> tag
The root element name 'html' is either missing from the <!DOCTYPE> tag, misspelt, or the wrong root element name has been used. You can find a list of the <!DOCTYPE> tags that Total Validator recognises here.
The keyword 'PUBLIC' is missing from the <!DOCTYPE> tag
The keyword 'PUBLIC' is either missing from the <!DOCTYPE> tag, or misspelt. You can find a list of the <!DOCTYPE> tags that Total Validator recognises here.
The word '!DOCTYPE' must be in uppercase for XHTML documents
The name '!DOCTYPE' must be all in uppercase for XHTML documents. You can find a list of the <!DOCTYPE> tags that Total Validator recognises here.
The keyword 'PUBLIC' must be in uppercase for XHTML documents
The keyword 'PUBLIC' must be all in uppercase for XHTML documents. You can find a list of the <!DOCTYPE> tags that Total Validator recognises here.
The root element name 'html' must be in lowercase for XHTML documents
The root element name 'html' must be all in in lowercase for XHTML documents. You can find a list of the <!DOCTYPE> tags that Total Validator recognises here.
The character set is not recognised
The character set specified is not recognised. This may be because it is misspelled.
There can be only one labelable element associated with a <label>
The <label> tag can only refer to one labelable element. In this case there is either more than one labelable element within the <label> tag, and/or the <label> tag has a 'for' attribute which refers to a labelable element that is found elsewhere.
The default scripting language must be specified for an intrinsic event
When intrinsic events onclick, onmouseover etc are specified the default scripting language should be specified using a Content-Script-Type HTTP header or <meta> tag. See https://www.w3.org/TR/html401/interact/scripts.html#h-18.2.2.1 (displayed in new window).
The default style sheet language must be specified when style attributes are used
When style attributes are used the default style sheet language should be specified using a Content-Style-Type HTTP header or <meta> tag. See https://www.w3.org/TR/html401/present/styles.html#h-14.2.1 (displayed in new window).
The value of the 'for' attribute must match the 'id' of the control element it refers to
When you include a 'for' attribute to associate a label with a control you must provide a control with a matching 'id' value in the same document. See https://www.w3.org/TR/html5/sec-forms.html#element-attrdef-label-for (displayed in new window).
The values in the 'headers' attribute must have matching the table cell 'ids'
When you include a 'headers' attribute to associate one cell with another you must provide matching 'ids' in cells in the same table. See https://www.w3.org/TR/html5/tabular-data.html#attributes-common-to-td-and-th-elements (displayed in new window), and https://www.w3.org/TR/html401/struct/tables.html#edef-TD (displayed in new window).
The value of the 'usemap' attribute must match the 'id' or 'name' of the <map> it refers to
When you include a 'usemap' attribute for a client-side map you must provide a <map> with a matching 'id' or 'name'.
The keyword 'SYSTEM' is missing from the <!DOCTYPE> tag
The keyword 'SYSTEM' is either missing from the <!DOCTYPE> tag, or misspelt. You can find a list of the <!DOCTYPE> tags that Total Validator recognises here.
The keyword 'SYSTEM' must be in uppercase for XHTML documents
The keyword 'SYSTEM' must be all in uppercase for XHTML documents. You can find a list of the <!DOCTYPE> tags that Total Validator recognises here.
The 'ATTRIBUTE NAME' attribute has an invalid character at position: INDEX
The specification being validated against does not allow attribute names with certain characters in them, this restriction may include namespace prefixes.
The 'xml:lang' and 'lang' attributes must have the same value
When 'xml:lang' and 'lang' attributes appear in the same element they must have the same value.
The 'xml:lang' and 'lang' attributes must have the same value
When the 'xml:lang' attribute is used you must also add a 'lang' attribute to the same element. See https://www.w3.org/TR/html5/ (displayed in new window).
The values in the 'for' attribute must have matching ids
When you include a 'for' attribute each of the ids listed must match elements elsewhere in the document.
The value of the 'list' attribute must match the 'id' of the <datalist> it refers to
When you include a 'list' attribute you must provide a <datalist> with a matching 'id'.
The value of the 'contextmenu' attribute must match the 'id' of the <menu> it refers to
When you include a 'contextmenu' attribute you must provide a <menu> with a matching 'id'.
The value of the 'form' attribute must match the 'name' or 'id (HTML5) of the <form> it refers to
When you include a 'form' attribute you must provide a <form> with a matching 'name' or 'id (HTML5).
The value of the 'refid' attribute must match the 'id' of the element it refers to
When you include a 'refid' attribute you must provide an element with a matching 'id'.
An attribute is not allowed for this input 'type'
For each 'type' attribute only a limited set of other attributes are allowed. See the relevant HTML standard for details.
Attribute missing, or conflicting ones specified
Exactly one of the 'name', 'http-equiv', 'charset', 'property', and 'itemprop' attributes must be specified.
Only one charset may be specified per document
You can only use one <meta> tag with a 'charset' or 'http-equiv=content-type' attribute.
For XHTML documents the value must be 'UTF-8'
For XHTML documents the 'charset' attribute must be a case-insensitive match for 'UTF-8'.
Missing value for 'content' attribute
If either 'name', 'http-equiv', 'property' or 'itemprop' is specified, then the 'content' attribute must have a value.
The 'ATTRIBUTE NAME' attribute is not allowed in this context
The HTML specification being validated against specifies that the attribute is not allowed due to other restrictions.
Invalid value for 'type' attribute
If the 'language' attribute is specified on the <script> tag then the 'type' attribute must be omitted or be equal to 'text/javascript'.
The charset part of the 'content' attribute is missing
The 'content' attribute must contain a 'charset' value.
Obsolete value for 'http-equiv'
Using the <meta> element to specify the document-wide default language is obsolete. Consider specifying the language on the root element instead.
The 'summary' attribute is obsolete
Authors are encouraged to consider whether the explanatory text in the 'summary' attribute is likely to be useful to the visually impaired, and also whether it would be more useful to the visually unimpaired to put this before the table or in a <caption>.
Self-closing tags are not allowed for this element
You can only use self-closing tags with 'void' elements whose content model is EMPTY. See "https://www.w3.org/TR/html5/syntax.html#start-tags (displayed in new window).
The value of the 'menu' attribute must match the 'id' of the <menu> it refers to
When you include a 'menu' attribute you must provide a <menu> with a matching 'id'.
ARIA attributes such as 'role' and 'aria-...' are invalid here
Some elements (sometimes combined with certain attributes) can not have ARIA attributes specified. See https://www.w3.org/TR/html-aria/#docconformance (displayed in new window).
The value of the 'role' attribute is not valid for this element
Elements can only have specific roles as defined by the ARIA specification. So you may be better off using a more appropriate element for this role. See https://www.w3.org/TR/html-aria/#docconformance (displayed in new window).
The 'ATTRIBUTE NAME' attribute for this ARIA role is missing
The ARIA specification requires that the attribute indicated should be used with the specified role(s). See https://www.w3.org/TR/wai-aria-1.1/ (displayed in new window).
The 'ATTRIBUTE NAME' attribute is not allowed in this context
The ARIA specification only allows certain 'aria-...' attributes to be used with certain roles. See https://www.w3.org/TR/wai-aria-1.1/ (displayed in new window).
Elements with the 'ROLE' role must be owned by an element with one of these roles: LIST OF ROLES
The ARIA specification requires that elements with certain roles must be contained within or owned by elements with other roles. So you need to add one of the roles listed to an owning element. See https://www.w3.org/TR/wai-aria-1.1/ (displayed in new window).
The value of the attribute must match an 'id' in the same document
Each of the ids listed for this aria attribute must match elements elsewhere in the document. See https://www.w3.org/TR/wai-aria-1.1/ (displayed in new window).
The value of the 'alt' attribute must must contain a non-empty string
The alt attribute must be present, and must contain a non-empty string giving the label that would be appropriate for an equivalent button if the image was unavailable. See https://www.w3.org/TR/html5/sec-forms.html#image-button-state-typeimage (displayed in new window).

top

HTML warnings

Warnings due to non-conformance with the chosen HTML specification

Code
Summary
Details
The 'ATTRIBUTE NAME' attribute has a boolean value, and this may be ignored or cause errors in older browsers/robots
Some older browsers and search engine robots do not recognise XHTML style boolean attributes such as selected="selected". For backwards compatibility just use the attribute without any value, e.g. 'selected'
The 'ATTRIBUTE NAME' attribute for this tag is recommended, but missing
Although this attribute is not required it is recommended that you add it for clarity.
The <!DOCTYPE> tag does not match the HTML specification being checked against
The <!DOCTYPE> tag should exactly match the one that uniquely identifies the specification being tested. You can find a list of the <!DOCTYPE> tags that Total Validator recognises here.
The system ID is missing from the <!DOCTYPE> tag
Although not a serious problem, the <!DOCTYPE> tag should exactly match the one that uniquely identifies the specification that the page follows. In this case the system ID is missing and should be added for completeness. This is a URL pointing to the DTD used to validate the page. You can find a list of the <!DOCTYPE> tags that Total Validator recognises here.
The 'content' attribute should have a value of 'application/xhtml+xml' for XHTML
Note that <meta> tags override HTTP headers and XHTML should be served with a content type of 'application/xhtml+xml'. See https://www.w3.org/TR/2009/NOTE-xhtml-media-types-20090116/#media-types (displayed in new window).
The 'content-type' http header should have a value of 'application/xhtml+xml' for XHTML
XHTML should be served with a content type of 'application/xhtml+xml'. See https://www.w3.org/TR/2009/NOTE-xhtml-media-types-20090116/#media-types (displayed in new window).
The 'content-type' HTTP header specifies a different character set
The 'content-type' HTTP header specifies a different character set to that specified in the tag. In this case the HTTP header takes precedence.
The BOM specifies a different character set
The BOM (Byte Order Mark) of the document specifies a different character set to that specified in the tag. In this case the BOM takes precedence.
No character set is specified in either the HTTP header, <meta> tag, or XML declaration
The character set (character encoding) should be specified in either a HTTP header or <meta> tag, or XML declaration for XHTML documents. If it isn't then the user agent may select an incorrect character set by mistake. See https://www.w3.org/TR/html5/syntax.html#determining-the-character-encoding (displayed in new window), and https://www.w3.org/TR/html401/charset.html#h-5.2.2 (displayed in new window).
The 'border' attribute is obsolete
Authors should not specify a 'border' attribute on an <img> element. CSS should be used instead.
The 'name' attribute is obsolete
The 'name' attribute on the <a> element is obsolete. Consider putting an 'id' attribute on the nearest container instead.
The 'language' attribute is obsolete
Authors should not specify the 'language' attribute on the <script> element. The 'type' attribute should be used instead.
With XHTML you should not use the 'content' attribute to set the content type or character set
With XHTML the character set should be set by an XML declaration or HTTP header.
Unrecognised value for the 'name' attribute
The 'name' attribute in the <meta> element is restricted to values documented in the HTML5 specification with extensions in the WHATWG Wiki. Note that Total Validator will not recognise changes to the wiki after its release date. So you will have to wait until the next release of Total Validator before new names are recognised. See https://wiki.whatwg.org/wiki/MetaExtensions (displayed in new window).
You should not use ARIA roles, that are the default for the element
Web developers should not set the ARIA role and aria-* attributes to values that match the default implicit ARIA semantics. See https://www.w3.org/TR/html-aria/#rules-wd (displayed in new window).
You should not use ARIA attributes that are implicitly defined by other attributes
Web developers should not set the ARIA role and aria-* attributes to values that match the default implicit ARIA semantics. See https://www.w3.org/TR/html-aria/#docconformance (displayed in new window).

top