Id attribute is unique
Last updated:
Created by:
Success Criterion:
Last updated:
Created by:
Success Criterion:
This rule checks that all id
attribute values on a single page are unique.
This conformance rule relates to:
Any id
attribute specified on an HTML or SVG element.
Note: Elements that are neither included in the accessibility tree nor visible on the page are still considered for this rule.
The value of the attribute is unique across all other id
attributes specified on HTML or SVG elements that exist within the same document tree or shadow tree as the element on which the applicable id
attribute is specified.
There are currently no assumptions.
There are no major accessibility support issues known for this rule.
Only one id
within the document context
All id
s are unique within the document context
id
in shadow DOM is for the same element as id
in light DOM
Several elements have identical id
Elements of different types have identical id
Having display: none
on an element still makes it applicable to this rule
No id
on element
XML id
not applicable to this rule
Elements included in the accessibility tree of platform specific accessibility APIs. Elements in the accessibility tree are exposed to assistive technologies, allowing users to interact with the elements in a way that meet the requirements of the individual user.
The general rules for when elements are included in the accessibility tree are defined in the core accessibility API mappings. For native markup languages, such as HTML and SVG, additional rules for when elements are [included in the accessibility tree][] can be found in the HTML accessibility API mappings and the SVG accessibility API mappings.
Note: Users of assistive technologies might still be able to interact with elements that are not included in the accessibility tree. An example of this is a focusable element with an
aria-hidden
attribute with a value oftrue
. Such an element could still be interacted with using sequential keyboard navigation regardless of the assistive technologies used, even though the element would not be included in the accessibility tree.
Elements should be visible on the page, and also meet the requirements for color contrast and visibility when focused. For more details, check out:
Content perceivable through sight.
Content is considered visible if making it fully transparent would result in a difference in the pixels rendered for any part of the document that is currently within the viewport or can be brought into the viewport via scrolling.
DOM Tree
Contributing is open to anyone. We welcome any new issues or pull requests for changes. Auto WCAG Rules has conference calls every 4 weeks. If you are interested in becoming an active contributor or reviewer, we ask that you join the Auto WCAG Rules community group through the W3C Website. This requires setting up a W3C account, may require approval by the organization you work for if they are a W3C member.
Learn more about contributing to Auto WCAG Rules Join the Auto WCAG Rules community group now!