Skip to main contentCarbon Design System

Button

The following page documents visual specifications such as color, typography, structure, and size.

Color

Primary button color

ElementPropertyColor token
Labeltext color
$text-on-color
Iconsvg
$icon-on-color
Containerbackground-color
$button-primary
Primary button color
Primary button interactive state color
StateElementPropertyColor token
HoverContainerbackground-color
$button-primary-hover
FocusContainerborder
$focus
inset
$focus-inset
ActiveContainerbackground-color
$button-primary-active
DisabledLabeltext-color
$text-on-color-disabled
Iconsvg
$icon-on-color-disabled
Containerbackground-color
$button-disabled
Primary button interactive states color

Secondary button color

ElementPropertyColor token
Labeltext color
$text-on-color
Iconsvg
$icon-on-color
Containerbackground-color
$button-secondary
Secondary button color
Secondary button interactive state color
StateElementPropertyColor token
HoverContainerbackground-color
$button-secondary-hover
FocusContainerborder
$focus
inset
$focus-inset
ActiveContainerbackground-color
$button-secondary-active
DisabledLabeltext-color
$text-on-color-disabled
Iconsvg
$icon-on-color-disabled
Containerbackground-color
$button-disabled
Secondary button interactive states color

Tertiary button color

ElementPropertyColor token
Labeltext color
$button-tertiary
Iconsvg
$button-tertiary
Containerbackground-color
transparent
border
$button-tertiary
Tertiary button color
Tertiary button interactive state color
StateElementPropertyColor token
HoverLabeltext-color
$text-inverse
Iconsvg
$icon-inverse
Containerbackground-color
$button-tertiary-hover
FocusContainerbackground-color
$button-tertiary-hover
border
$focus
inset
$focus-inset
ActiveLabeltext-color
$text-inverse
Iconsvg
$icon-inverse
Containerbackground-color
$button-tertiary-active
DisabledLabeltext-color
$text-disabled
Iconsvg
$icon-disabled
Containerbackground-color
transparent
border
$button-disabled
Tertiary button interactive states color

Ghost button color

Ghost button color
ElementPropertyColor token
Labeltext color
$link-primary
Iconsvg
$link-primary
Containerbackground-color
transparent
Ghost icon only button color
ElementPropertyColor token
Iconsvg
$icon-primary
Containerbackground-color
transparent
Ghost button color
Ghost button interactive state color
StateElementPropertyColor token
HoverLabeltext-color
$link-primary-hover
Iconsvg
$link-primary-hover
Containerbackground-color
$background-hover
FocusContainerbackground-color
$focus
ActiveContainerbackground-color
$background-hover
DisabledLabeltext-color
$text-disabled
Iconsvg
$icon-disabled
Ghost icon only button interactive state color
StateElementPropertyColor token
HoverContainerbackground-color
$background-hover
FocusContainerborder
$focus
ActiveContainerbackground-color
$background-active
SelectedContainerbackground-color
$background-selected
DisabledIconsvg
$icon-disabled
Ghost button interactive states color

Danger primary button color

ElementPropertyColor token
Labeltext color
$text-on-color
Iconsvg
$icon-on-color
Containerbackground-color
$button-danger-primary
Danger primary color

Danger primary button color

Danger primary button interactive state color
StateElementPropertyColor token
HoverContainerbackground-color
$button-danger-hover
FocusContainerborder
$focus
inset
$focus-inset
ActiveContainerbackground-color
$button-danger-active
DisabledLabeltext-color
$text-on-color-disabled
Iconsvg
$icon-on-color-disabled
Containerbackground-color
$button-disabled
Danger primary button interactive states color

Danger primary button interactive state color

Danger tertiary button color

ElementPropertyColor token
Labeltext color
$button-danger-secondary
Iconsvg
$button-danger-secondary
Containerborder
$button-danger-secondary
Danger tertiary color

Danger tertiary button color

Danger tertiary button interactive state color
StateElementPropertyColor token
HoverLabeltext-color
$text-on-color
Iconsvg
$icon-on-color
Containerbackground-color
$button-danger-hover
Focusborder
$focus
inset
$focus-inset
ActiveLabeltext-color
$text-on-color
Iconsvg
$icon-on-color
Containerbackground-color
$button-danger-active
DisabledLabeltext-color
$text-disabled
Iconsvg
$icon-disabled
Containerbackground-color
$button-disabled
Danger tertiary button interactive state color

Danger tertiary button interactive state color

Danger ghost button color

ElementPropertyColor token
Labeltext color
$button-danger-secondary
Iconsvg
$button-danger-secondary
Containerbackground-color
transparent
Danger ghost button color

Danger ghost button color

Danger ghost button button interactive state color
StateElementPropertyColor token
HoverLabeltext-color
$text-on-color
Iconsvg
$icon-on-color
Containerbackground-color
$button-danger-hover
Focusborder
$focus
inset
$focus-inset
ActiveLabeltext-color
$text-on-color
Iconsvg
$icon-on-color
Containerbackground-color
$button-danger-active
DisabledLabeltext-color
$text-disabled
Iconsvg
$icon-disabled
Containerbackground-color
$button-disabled
Danger ghost button interactive state color

Danger ghost button interactive state color

Typography

Button text should be set in sentence case, with only the first word in a phrase and any proper nouns capitalized.

ElementFont-size (px/rem)Font-weightType token
Button text14 / 0.875Regular / 400
$body-compact-01
Button text (expressive)16 / 1Regular / 400
$body-compact-02

Structure

Primary, Secondary, Tertiary, Danger Primary and Danger tertiary button follows the same structure measurements. A button cannot have any element or text within 16 pixels / 1 rem of its borders. For a button with a glyph, the space between the button label and the glyph must be greater than or equal to 16 pixels / 1 rem. This is to accommodate for instances where two or more buttons with glyphs appear together.

Button structure

ElementPropertypx / remSpacing token
Button without iconpadding-left16 / 1
$spacing-05
padding-right64 / 4
$spacing-10
Button with iconpadding-left, padding-right16 / 1
$spacing-05
spacing32 / 2
$spacing-07
Icon only buttonpadding-left, padding-right16 / 1
$spacing-05
Iconsvg16 x 16–
Icon: expressivesize20 x 20–
Focusbox-shadow: inset1px–
Button structure

Structure measurements for a button | px / rem

Ghost button structure

Ghost and Danger ghost button follow the same structure measurements.

ElementPropertypx / remSpacing token
Ghost button without iconpadding-left, padding-right16 / 1
$spacing-05
Ghost button with iconspacing8 / 0.5
$spacing-03
Ghost icon only buttonpadding-left, padding-right16 / 1
$spacing-05
Ghost button structure

Structure measurements for ghost button | px / rem

Button groups structure

The following specs are not built into any of the button components but are recommended by design as the proper distance between buttons.

For button groups, the primary button is positioned on the outside of the set, while the secondary button is positioned inside.

ElementPropertypx / remSpacing token
Button groupsborder (fluid)1px–
spacing (fixed)16px
$spacing-05
margin-left, margin-right0–
Button groups structure

Structure measurements for button groups | px / rem

Sizes

There are six button sizes: small, medium, large productive, large expressive, extra large, and 2XL. The large expressive button is used in editorial and digital marketing experiences. See Button sizes on the Usage tab for more information about specific use cases for each button size.

VariantSizeHeight (px / rem)
ButtonSmall32 / 2
Medium40 / 2.5
Large productive48 / 3
Large expressive48 / 3
Full bleed buttonExtra large64 / 4
2XL80 / 5
Button sizes

Button sizes

Feedback

Help us improve this component by providing feedback, asking questions, and leaving any other comments on GitHub.