# Non-text Contrast: 3:1 for Icons, Borders and Focus

Source: https://allyway.ai/glossary/non-text-contrast

Non-text Contrast is WCAG success criterion 1.4.11. The visual parts needed to identify user interface components and their states, and the parts of graphics needed to understand content, must have a contrast ratio of at least 3:1 against adjacent colors.

Non-text Contrast is the WCAG rule that controls and meaningful graphics must stand out from their surroundings – not just text. A light grey input border, a pale checkbox or a faint focus ring may look elegant, but people with low vision can miss them entirely. The requirement is a contrast ratio of at least 3:1.

## What it means

[WCAG 1.4.11 Non-text Contrast](https://www.w3.org/WAI/WCAG22/Understanding/non-text-contrast.html) is a Level AA criterion of [WCAG 2.2](https://allyway.ai/regulations/wcag-2-2). It covers two groups:

| Group | What needs 3:1 against adjacent colors | Exception |
|---|---|---|
| User interface components | Visual information needed to identify a control and its state – input borders, checkbox outlines, toggle positions, focus indicators | Inactive (disabled) components; controls whose look comes from the browser and was not changed by the author |
| Graphical objects | Parts of graphics needed to understand the content – icons without text, [chart lines](https://allyway.ai/glossary/accessible-charts), infographic segments | A particular presentation that is essential, e.g. a logo in its mandated brand colors |

W3C is strict about the threshold: computed values are not rounded, so 2.999:1 fails. Colors are taken from the code, not from what the screen seems to show – thin lines can look fainter because of anti-aliasing, so W3C advises avoiding very thin lines.

Text is not part of this criterion: [text in images](https://allyway.ai/glossary/images-of-text) and on buttons follows [color contrast](https://allyway.ai/glossary/color-contrast) (1.4.3) with 4.5:1. Hover effects are extra information and do not need 3:1 themselves. Focus indicators do – which ties 1.4.11 closely to [focus visible](https://allyway.ai/glossary/focus-visible).

> **Tip:** > **One shade decides**
> On a white background, the grey `#949494` reaches 3.03:1 and passes. `#959595` reaches only 2.995:1 and fails – a difference you cannot see but a contrast tool can measure.

W3C's failure F78 is removing or hiding the focus indicator through outline or border styles – it fails both 1.4.11 and 2.4.7.

## Examples

Contrast ratios below are against a white background (#FFFFFF), computed with the WCAG formula:

| Element | Color | Ratio | Result |
|---|---|---|---|
| Input border | `#767676` | 4.54:1 | Pass |
| Checkbox border | `#9D9D9D` | 2.71:1 | Fail |
| Input border | `#CCCCCC` | 1.61:1 | Fail |
| Focus outline | `#0048FE` | 6.25:1 | Pass |

```html title="Example"
<style>
  /* Good: field border and focus ring meet 3:1 on white */
  input { border: 1px solid #767676; }
  input:focus-visible { outline: 3px solid #0048FE; outline-offset: 2px; }

  /* Bad: border too light to find the field (1.61:1) */
  .search input { border: 1px solid #ccc; }

  /* Bad: focus indicator removed (F78) */
  button:focus { outline: none; }
</style>

<!-- Good: icon-only button with a dark icon and a name -->
<button aria-label="Search">
  <svg aria-hidden="true" fill="#1F2937">…</svg>
</button>
```

**Do:** Do

Give input fields, checkboxes and radio buttons a border of at least 3:1, design a clear focus ring (W3C techniques G195, C40), use dark enough colors for meaningful icons – especially on an [icon button](https://allyway.ai/glossary/icon-button) – and add patterns or labels to chart segments that sit next to each other.

**Don't:** Don't

Rely on a pale fill to show where a field is, remove `outline` without a replacement, show the selected state of a toggle only with a subtle tint, or use light grey icons as the only way to identify a control.

## How to check non-text contrast



## Questions

Q: What is non-text contrast in WCAG?
A: It is success criterion 1.4.11 at Level AA. Visual information that identifies controls and their states, and parts of graphics needed to understand content, must reach at least 3:1 against adjacent colors.

Q: Do input borders need 3:1 contrast?
A: Yes, if the border is what shows where the field is. If the field has a filled background that reaches 3:1 against the page, the border itself does not need to.

Q: Do disabled buttons need to meet non-text contrast?
A: No. W3C exempts inactive components. They should still look clearly disabled so nobody tries to use them.

Q: Do logos have to meet 3:1?
A: Only logos whose colors are mandated by brand guidelines are exempt. A low-contrast graphic that is simply a design choice is not.

Q: How do I measure non-text contrast?
A: Take the color of the border, icon or focus ring and the adjacent background color from the code and compare them. The free allyWay [contrast checker](https://allyway.ai/free-wcag-contrast-checker) shows the ratio for any color pair.
