[Back to 2 Operable index](index.html) # 2.5.3 Label in Name - Level: A - Guideline: 2.5 Input Modalities - Principle: 2 Operable ## What it is For user interface components with labels that include text or images of text, the name contains the text that is presented visually. ## How to test - Check: For user interface components with labels that include text or images of text, the name contains the text that is presented visually. - Use the sufficient techniques below as acceptable methods when applicable. - Confirm none of the common failures apply. ## Sufficient techniques (W3C) - G208: Including the text of the visible label as part of the accessible name - G211: Matching the accessible name to the visible label ## Advisory techniques (W3C) - G162: Positioning labels to maximize predictability of relationships - If an icon has no accompanying text, consider using its hover text as its accessible name (Potential future technique) ## Common failures (W3C) - F96: Failure due to the accessible name not containing the visible label text - F111: Failure of Success Criteria 1.3.1, 2.5.3, and 4.1.2 due to a control with visible label text but no accessible name - Accessible name contains the visible label text, but the words of the visible label are not in the same order as they are in the visible label text (Potential future technique) - Accessible name contains the visible label text, but one or more other words are interspersed in the label (Potential future technique) ## Notes - Note: A best practice is to have the text of the label at the start of the name. ## Resources - WCAG 2.2 SC: https://www.w3.org/TR/WCAG22/#label-in-name - Understanding: https://www.w3.org/WAI/WCAG22/Understanding/label-in-name.html - Quick reference: https://www.w3.org/WAI/WCAG22/quickref/?versions=2.2#label-in-name [Back to 2 Operable index](index.html)