Icon button
An icon button is a button that shows a glyph in place of words. Use it where the glyph is familiar to all who see it, and give it a label for the tooltip and the screen reader.
Anatomy and sizes
The glyph sits at the center of a square box with corners of 8px, the same as a button's, so the two read as one family.
Medium is the default. Small fits table rows and dense toolbars, and large lines up with medium buttons.
- Small
- 32 px box, 16 px glyph
- Medium
- 40 px box, 20 px glyph
- Large
- 44 px box, 20 px glyph
- Corner radius
- 8 px
- --radius-lg
- Glyph stroke
- 1.75 on a 24 unit grid
- Touch target
- 44 px on touch screens
When to use it
Use an icon button for an action whose glyph people read at once, such as closing a panel, copying a link or opening more actions. It suits toolbars, headers and table rows, where words would crowd the space.
When people would have to guess, write the words on a button. A destructive glyph, such as the trash on a candidate row, never acts alone: it opens a confirmation, or it deletes and offers Undo.
Variants and states
| Variant | Rest | Hover | Pressed | Focus | Disabled | Toggle on |
|---|---|---|---|---|---|---|
| Quiet | ||||||
| Secondary |
Label and tooltip
The label is a verb and its object: Close panel, Copy link, More actions. A screen reader reads it as the name, and the tooltip shows the same words on hover and on keyboard focus.
A count on the button, such as unread notifications, joins the name: Notifications, 3 unread.
Keyboard and touch
Tab reaches an icon button, and Enter or Space presses it. One that opens a menu opens it on the down arrow too, as a menu button does.
On a touch screen the target is 44 px whatever the box. Keep the centers of neighboring icon buttons at least 44 px apart: 12 px between small boxes, 4 px between medium ones.
Permitted and not permitted
Permitted
Close panel with the cross glyph
A glyph people name the same way
More actions at the end of a candidate row
One small button that opens the row menu
Not permitted
A drawn glyph for Approve visa
Nobody can guess it, so write the words on a button
A red delete glyph that deletes at once
A destructive action needs words or Undo