2026-11-01 · UI Design
Most icon accessibility problems come from two mistakes: unnamed icon-only buttons and meaning carried by colour alone. Here is how to fix both and audit a screen in ten minutes.
Every accessibility decision for an icon starts with one question: does it add information that the surrounding text does not already give? A trash can next to the word "Delete" adds nothing for a screen reader user, because the button already says Delete. The same trash can alone inside a button is the only label that button has.
That gives you two cases. A decorative icon sits beside visible text, or is purely ornamental, and should be hidden from assistive technology. An informative icon stands alone, and needs a text alternative. Most of the mistakes in real interfaces come from treating both cases the same way, usually by leaving every icon exposed with no name, or by adding a label to icons that are already described by their neighbours.
Go through your icon set and tag each use as decorative or informative before you touch any markup. A spreadsheet with three columns (icon, where it is used, decorative or informative) takes about 15 minutes for 40 icons and saves a lot of guesswork later.
For a decorative inline SVG, add aria-hidden="true" to the <svg> element and focusable="false" for older browsers that would otherwise make the SVG a tab stop. Example: <svg aria-hidden="true" focusable="false" viewBox="0 0 24 24">. Do not add a <title> inside it. A title on a hidden icon can still produce a hover tooltip for mouse users, which is rarely what you want next to a visible label.
If you load the icon with an <img> tag, use an empty alt attribute (alt=""). That tells screen readers to skip the image. Leaving alt off entirely is worse: some screen readers then read out the file name, so you hear something like "icon-arrow-right-v2 dot svg".
One trap with CSS background images: they are invisible to assistive technology, which is fine for decoration but means they can never carry meaning. If an icon conveys state (an error, a warning, a completed step), do not deliver it as a background-image alone.
When an icon is the only content of a button or link, give the control its name, not the SVG. The most reliable pattern is an aria-label on the button: <button aria-label="Delete invoice"> with the SVG inside marked aria-hidden="true". The accessible name comes from one place, the button, and the icon stays out of the way.
An alternative that works well in a design system is visually hidden text: <button><svg aria-hidden="true">...</svg><span class="sr-only">Delete invoice</span></button>. The advantage is that the text is real content, so browser translation tools can translate it. An aria-label is not always translated, which matters if your product ships in more than one language.
Write names that describe the action or the destination, not the picture. "Delete invoice" is useful; "trash can" is not. "Settings" is useful; "gear" is not. Keep names short, around two to four words, and make them unique where several identical icons repeat in a list. Ten rows each with a button named "Delete" give a screen reader user a list of ten identical options. "Delete invoice 1042" tells them which one they are on.
Sometimes an SVG is not inside a control: a status icon in a table cell, a logo mark in a header, or an illustration that carries meaning. For these, use role="img" on the <svg> and give it a name. The simplest way that works across browsers is aria-label: <svg role="img" aria-label="Payment failed" viewBox="0 0 24 24">.
A <title> element as the first child of the <svg> also works and gives sighted mouse users a tooltip. If you use it, link it with aria-labelledby pointing at the title's id, because some browser and screen reader pairings ignore a bare <title>. Do not rely on <desc> for anything essential; support is inconsistent, so put important information in visible text or the name itself.
For complex graphics such as charts or diagrams, a short name is not enough. Give the graphic a one-sentence name and put the full explanation in text next to it, such as a caption or a data table. An icon, by contrast, should never need a paragraph to explain it. If it does, the icon is too abstract.
WCAG 1.4.1 says colour cannot be the only way to convey information. A red circle and a green circle that differ only in hue fail for people with colour vision deficiency, and for anyone viewing a screen in bright sunlight or greyscale. Pair colour with a shape change. Use a check mark for success, an exclamation mark in a triangle for warning, and an X in a circle for error. If your set draws all three states as the same circle, redraw two of them.
Contrast matters as well. WCAG 2.1 success criterion 1.4.11 requires non-text elements that are needed to understand the interface, including icons that carry meaning, to have a contrast ratio of at least 3:1 against adjacent colours. A light grey 24 px icon (#9CA3AF) on a white background measures roughly 2.5:1, which fails. Darkening it to #6B7280 gives roughly 4.8:1, which passes. Check your actual colours with any contrast checker rather than trusting these approximations; they are there to show the size of the gap, not to replace a measurement.
Decorative icons are exempt from the contrast requirement, but meaningful ones are not, and disabled controls are exempt too. Test the icon states you ship: default, hover, focus, selected.
A 24 px icon is a good drawing size, but it is a poor tap target on its own. WCAG 2.2 criterion 2.5.8 (Target Size, Minimum) sets 24 by 24 CSS pixels as the minimum for pointer targets, with some exceptions for spacing. Many platform guidelines recommend larger, in the 44 to 48 px range for touch.
The practical fix is padding, not a bigger icon. Keep the glyph at 24 px and wrap it in a button with 10 px of padding on each side, which gives a 44 px target. Check that neighbouring targets do not overlap; an icon toolbar with 4 px gaps and 44 px buttons is fine, while 24 px icons packed with no gap are not.
Show keyboard focus too. Never remove the default outline without replacing it. A 2 px outline offset by 2 px, in a colour with at least 3:1 contrast against the background, is a reliable replacement. It should be visible on every background your icons sit on, including dark mode and image overlays.
The cheapest place to fix this is the component that wraps your icons. Make a single Icon component with two modes: decorative by default (aria-hidden, no label) and informative when a label prop is passed (role="img" plus aria-label). Then make an IconButton component that requires a label prop and fails in development or lint if it is missing. Designers and developers then cannot ship an unnamed icon-only button without noticing.
On the design side, keep the stroke weight consistent across the set (2 px on a 24 px grid is a common choice) so that icons stay legible at small sizes, and leave a 2 px padding inside the 24 px viewBox so strokes are not clipped by focus outlines or overflow rules. Use the same shape for the same meaning everywhere. If a bell means notifications on one screen, do not use it for reminders on another.
If you generate a set rather than drawing it by hand, the same checks apply: the output is a starting point, and the naming, contrast and target-size decisions are still yours. VEXURA's icon generator at /icons produces SVG icons from a text prompt; you still apply the labelling pattern above when you place them in your product.
Pick one screen and work through this list. First, tab through it with the keyboard only. Every icon button should take focus, show a visible outline, and trigger on Enter or Space. Second, turn on a screen reader (VoiceOver on macOS and iOS, NVDA on Windows, TalkBack on Android) and listen. Any control announced as just "button" or "link" has no name. Third, zoom the page to 200% and confirm icons and labels still fit. Fourth, run a contrast checker on every icon that carries meaning, aiming for 3:1 or better. Fifth, view the screen in greyscale (most operating systems have a colour filter setting) and see whether success, warning and error states are still distinguishable.
Write down what fails, fix the shared component first, and only then patch individual screens. Most teams find that three or four fixes in the icon component clear the majority of issues across the whole product.