Harmony Site Theme CSS Variables

Wix Harmony exposes a set of CSS variables for a site's theme colors, fonts, and component styles.

Reference them in your app's CSS so its appearance follows the site's theme and updates when the site owner changes it.

These variables exist on Harmony sites only. Sites built in Wix Editor or Wix Studio expose a smaller set, listed in Site Theme CSS Variables.

Caution: Verify theme styling on a published page, not on the editor canvas.

In the editor, a custom element renders inside a sandbox that receives a fixed set of values. A variable there can:

  • Resolve to its fallback.
  • Resolve to a value that differs from the live site.
  • Stay the same when the site owner edits the theme.

On a published page, both Editor React Components and custom elements receive every variable listed here.

What the table columns mean

Each table groups the variables for one kind of style, and each row is one property of one style.

  • Style name: the label the site owner sees in the editor's Site Brand panel.
  • Property: the part of the style the variable controls.
  • CSS variable: the name to reference in your CSS.
  • Defaults to: the variable this one follows until the site owner changes it.
  • Value: the fixed value, in the System colors table only.

The Site Brand panel groups the palette and system colors without naming them individually, so those style names follow the variable names instead.

An empty Defaults to entry means the variable follows no other variable. Its value comes from the set the site owner selected, named at the start of each section, and it changes when they edit that set.

For example, changing Heading 1's color repoints --wst-heading-1-color at the color the owner chose, while --wst-heading-2-color keeps following Base 2's color. Reference the variable for the thing you are styling, not the one it follows.

Colors

A site's colors fall into three groups: semantic colors named for their use, the palette the site owner picks, and fixed system colors.

Semantic colors

Colors named for what they're used for. Prefer these over palette colors, so your app follows the meaning the site owner intended.

Style namePropertyCSS variableDefaults to
Primary backgroundColor--wst-primary-background-color--wst-base-1-color
Secondary backgroundColor--wst-secondary-background-color--wst-shade-1-color
Links and actionsColor--wst-links-and-actions-color--wst-accent-1-color
Graphics 1Color--wst-graphics-1-color--wst-base-2-color
Graphics 2Color--wst-graphics-2-color--wst-accent-1-color
DisabledColor--wst-system-disabled-color--wst-shade-2-color

Palette

The site owner picks these nine colors, and the rest of the theme takes its colors from them. Use one only when no semantic color fits what you are styling.

These nine come from the site's brand kit, the set of colors and fonts the owner selects in the editor's Site Brand panel. Switching to a different brand kit changes all nine, and everything that derives from them changes with it.

Style namePropertyCSS variable
Base 1Color--wst-base-1-color
Base 2Color--wst-base-2-color
Shade 1Color--wst-shade-1-color
Shade 2Color--wst-shade-2-color
Shade 3Color--wst-shade-3-color
Accent 1Color--wst-accent-1-color
Accent 2Color--wst-accent-2-color
Accent 3Color--wst-accent-3-color
Accent 4Color--wst-accent-4-color

System

Fixed values that aren't part of the site's palette.

Style namePropertyCSS variableValue
SuccessColor--wst-system-success-color#489F48
ErrorColor--wst-system-error-color#D82222
AlertColor--wst-system-alert-color#E98316
Default darkColor--wst-system-default-dark-color#000000
Default lightColor--wst-system-default-light-color#ffffff

Text

Nine text styles. Fonts come from the site's font set, and each color can be changed per style.

Style namePropertyCSS variableDefaults to
Heading 1Font--wst-heading-1-font
Heading 1Color--wst-heading-1-color--wst-base-2-color
Heading 2Font--wst-heading-2-font
Heading 2Color--wst-heading-2-color--wst-base-2-color
Heading 3Font--wst-heading-3-font
Heading 3Color--wst-heading-3-color--wst-base-2-color
Heading 4Font--wst-heading-4-font
Heading 4Color--wst-heading-4-color--wst-base-2-color
Heading 5Font--wst-heading-5-font
Heading 5Color--wst-heading-5-color--wst-base-2-color
Heading 6Font--wst-heading-6-font
Heading 6Color--wst-heading-6-color--wst-base-2-color
Paragraph 1Font--wst-paragraph-1-font
Paragraph 1Color--wst-paragraph-1-color--wst-base-2-color
Paragraph 2Font--wst-paragraph-2-font
Paragraph 2Color--wst-paragraph-2-color--wst-base-2-color
Paragraph 3Font--wst-paragraph-3-font
Paragraph 3Color--wst-paragraph-3-color--wst-base-2-color

Buttons

Three button tiers with the same properties. Values come from the site's button set, which the owner can swap or edit. Swapping to another set changes the borders, corner radii and spacing, and the colors keep following the same palette variables.

Style namePropertyCSS variableDefaults to
Primary ButtonFill color--wst-button-primary-background-color--wst-accent-1-color
Primary ButtonBorder color (left)--wst-button-primary-border-left-color--wst-base-2-color
Primary ButtonBorder color (right)--wst-button-primary-border-right-color--wst-base-2-color
Primary ButtonBorder color (top)--wst-button-primary-border-top-color--wst-base-2-color
Primary ButtonBorder color (bottom)--wst-button-primary-border-bottom-color--wst-base-2-color
Primary ButtonShadow--wst-button-primary-box-shadow
Primary ButtonBorder width (left)--wst-button-primary-border-left-width
Primary ButtonBorder width (right)--wst-button-primary-border-right-width
Primary ButtonBorder width (top)--wst-button-primary-border-top-width
Primary ButtonBorder width (bottom)--wst-button-primary-border-bottom-width
Primary ButtonBorder style (left)--wst-button-primary-border-left-style
Primary ButtonBorder style (right)--wst-button-primary-border-right-style
Primary ButtonBorder style (top)--wst-button-primary-border-top-style
Primary ButtonBorder style (bottom)--wst-button-primary-border-bottom-style
Primary ButtonPadding (bottom)--wst-button-primary-padding-bottom
Primary ButtonPadding (top)--wst-button-primary-padding-top
Primary ButtonPadding (left)--wst-button-primary-padding-left
Primary ButtonPadding (right)--wst-button-primary-padding-right
Primary ButtonCorner radius (top left)--wst-button-primary-border-top-left-radius
Primary ButtonCorner radius (top right)--wst-button-primary-border-top-right-radius
Primary ButtonCorner radius (bottom left)--wst-button-primary-border-bottom-left-radius
Primary ButtonCorner radius (bottom right)--wst-button-primary-border-bottom-right-radius
Primary ButtonHorizontal spacing--wst-button-primary-column-gap
Primary ButtonVertical spacing--wst-button-primary-row-gap
Primary ButtonText color--wst-button-primary-color--wst-base-1-color
Primary ButtonText highlight--wst-button-primary-text-highlight
Primary ButtonText font--wst-button-primary-font--wst-paragraph-2-font
Primary ButtonLetter spacing--wst-button-primary-letter-spacing
Primary ButtonText decoration--wst-button-primary-text-decoration
Primary ButtonCase--wst-button-primary-text-transform
Primary ButtonText shadow--wst-button-primary-text-shadow
Primary ButtonAlignment--wst-button-primary-justify-content
Primary ButtonFill image--wst-button-primary-background-image
Secondary ButtonFill color--wst-button-secondary-background-color--wst-base-1-color
Secondary ButtonBorder color (left)--wst-button-secondary-border-left-color--wst-accent-1-color
Secondary ButtonBorder color (right)--wst-button-secondary-border-right-color--wst-accent-1-color
Secondary ButtonBorder color (top)--wst-button-secondary-border-top-color--wst-accent-1-color
Secondary ButtonBorder color (bottom)--wst-button-secondary-border-bottom-color--wst-accent-1-color
Secondary ButtonShadow--wst-button-secondary-box-shadow
Secondary ButtonBorder width (left)--wst-button-secondary-border-left-width
Secondary ButtonBorder width (right)--wst-button-secondary-border-right-width
Secondary ButtonBorder width (top)--wst-button-secondary-border-top-width
Secondary ButtonBorder width (bottom)--wst-button-secondary-border-bottom-width
Secondary ButtonBorder style (left)--wst-button-secondary-border-left-style
Secondary ButtonBorder style (right)--wst-button-secondary-border-right-style
Secondary ButtonBorder style (top)--wst-button-secondary-border-top-style
Secondary ButtonBorder style (bottom)--wst-button-secondary-border-bottom-style
Secondary ButtonPadding (bottom)--wst-button-secondary-padding-bottom
Secondary ButtonPadding (top)--wst-button-secondary-padding-top
Secondary ButtonPadding (left)--wst-button-secondary-padding-left
Secondary ButtonPadding (right)--wst-button-secondary-padding-right
Secondary ButtonCorner radius (top left)--wst-button-secondary-border-top-left-radius
Secondary ButtonCorner radius (top right)--wst-button-secondary-border-top-right-radius
Secondary ButtonCorner radius (bottom left)--wst-button-secondary-border-bottom-left-radius
Secondary ButtonCorner radius (bottom right)--wst-button-secondary-border-bottom-right-radius
Secondary ButtonHorizontal spacing--wst-button-secondary-column-gap
Secondary ButtonVertical spacing--wst-button-secondary-row-gap
Secondary ButtonText color--wst-button-secondary-color--wst-accent-1-color
Secondary ButtonText highlight--wst-button-secondary-text-highlight
Secondary ButtonText font--wst-button-secondary-font--wst-paragraph-2-font
Secondary ButtonLetter spacing--wst-button-secondary-letter-spacing
Secondary ButtonText decoration--wst-button-secondary-text-decoration
Secondary ButtonCase--wst-button-secondary-text-transform
Secondary ButtonText shadow--wst-button-secondary-text-shadow
Secondary ButtonAlignment--wst-button-secondary-justify-content
Secondary ButtonFill image--wst-button-secondary-background-image
Tertiary ButtonFill color--wst-button-tertiary-background-color
Tertiary ButtonBorder color (left)--wst-button-tertiary-border-left-color
Tertiary ButtonBorder color (right)--wst-button-tertiary-border-right-color
Tertiary ButtonBorder color (top)--wst-button-tertiary-border-top-color
Tertiary ButtonBorder color (bottom)--wst-button-tertiary-border-bottom-color
Tertiary ButtonShadow--wst-button-tertiary-box-shadow
Tertiary ButtonBorder width (left)--wst-button-tertiary-border-left-width
Tertiary ButtonBorder width (right)--wst-button-tertiary-border-right-width
Tertiary ButtonBorder width (top)--wst-button-tertiary-border-top-width
Tertiary ButtonBorder width (bottom)--wst-button-tertiary-border-bottom-width
Tertiary ButtonBorder style (left)--wst-button-tertiary-border-left-style
Tertiary ButtonBorder style (right)--wst-button-tertiary-border-right-style
Tertiary ButtonBorder style (top)--wst-button-tertiary-border-top-style
Tertiary ButtonBorder style (bottom)--wst-button-tertiary-border-bottom-style
Tertiary ButtonPadding (bottom)--wst-button-tertiary-padding-bottom
Tertiary ButtonPadding (top)--wst-button-tertiary-padding-top
Tertiary ButtonPadding (left)--wst-button-tertiary-padding-left
Tertiary ButtonPadding (right)--wst-button-tertiary-padding-right
Tertiary ButtonCorner radius (top left)--wst-button-tertiary-border-top-left-radius
Tertiary ButtonCorner radius (top right)--wst-button-tertiary-border-top-right-radius
Tertiary ButtonCorner radius (bottom left)--wst-button-tertiary-border-bottom-left-radius
Tertiary ButtonCorner radius (bottom right)--wst-button-tertiary-border-bottom-right-radius
Tertiary ButtonHorizontal spacing--wst-button-tertiary-column-gap
Tertiary ButtonVertical spacing--wst-button-tertiary-row-gap
Tertiary ButtonText color--wst-button-tertiary-color--wst-accent-1-color
Tertiary ButtonText highlight--wst-button-tertiary-text-highlight
Tertiary ButtonText font--wst-button-tertiary-font--wst-paragraph-2-font
Tertiary ButtonLetter spacing--wst-button-tertiary-letter-spacing
Tertiary ButtonText decoration--wst-button-tertiary-text-decoration
Tertiary ButtonCase--wst-button-tertiary-text-transform
Tertiary ButtonText shadow--wst-button-tertiary-text-shadow
Tertiary ButtonAlignment--wst-button-tertiary-justify-content
Tertiary ButtonFill image--wst-button-tertiary-background-image

Boxes

Two box styles. Values come from the site's box set, which the owner can swap or edit.

Style namePropertyCSS variableDefaults to
Box 1Border width (left)--wst-box-primary-border-left-width
Box 1Border style (left)--wst-box-primary-border-left-style
Box 1Border color (left)--wst-box-primary-border-left-color--wst-base-2-color
Box 1Border width (right)--wst-box-primary-border-right-width
Box 1Border style (right)--wst-box-primary-border-right-style
Box 1Border color (right)--wst-box-primary-border-right-color--wst-base-2-color
Box 1Border width (top)--wst-box-primary-border-top-width
Box 1Border style (top)--wst-box-primary-border-top-style
Box 1Border color (top)--wst-box-primary-border-top-color--wst-base-2-color
Box 1Border width (bottom)--wst-box-primary-border-bottom-width
Box 1Border style (bottom)--wst-box-primary-border-bottom-style
Box 1Border color (bottom)--wst-box-primary-border-bottom-color--wst-base-2-color
Box 1Corner radius (top left)--wst-box-primary-border-top-left-radius
Box 1Corner radius (top right)--wst-box-primary-border-top-right-radius
Box 1Corner radius (bottom left)--wst-box-primary-border-bottom-left-radius
Box 1Corner radius (bottom right)--wst-box-primary-border-bottom-right-radius
Box 1Shadow--wst-box-primary-box-shadow
Box 1Background color--wst-box-primary-background-color--wst-shade-1-color
Box 1Fill image--wst-box-primary-background-image
Box 2Border width (left)--wst-box-secondary-border-left-width
Box 2Border style (left)--wst-box-secondary-border-left-style
Box 2Border color (left)--wst-box-secondary-border-left-color--wst-base-2-color
Box 2Border width (right)--wst-box-secondary-border-right-width
Box 2Border style (right)--wst-box-secondary-border-right-style
Box 2Border color (right)--wst-box-secondary-border-right-color--wst-base-2-color
Box 2Border width (top)--wst-box-secondary-border-top-width
Box 2Border style (top)--wst-box-secondary-border-top-style
Box 2Border color (top)--wst-box-secondary-border-top-color--wst-base-2-color
Box 2Border width (bottom)--wst-box-secondary-border-bottom-width
Box 2Border style (bottom)--wst-box-secondary-border-bottom-style
Box 2Border color (bottom)--wst-box-secondary-border-bottom-color--wst-base-2-color
Box 2Corner radius (top left)--wst-box-secondary-border-top-left-radius
Box 2Corner radius (top right)--wst-box-secondary-border-top-right-radius
Box 2Corner radius (bottom left)--wst-box-secondary-border-bottom-left-radius
Box 2Corner radius (bottom right)--wst-box-secondary-border-bottom-right-radius
Box 2Shadow--wst-box-secondary-box-shadow
Box 2Background color--wst-box-secondary-background-color--wst-base-1-color
Box 2Fill image--wst-box-secondary-background-image

Lines

Two line styles. Widths come from the site's line set, which the owner can edit.

Style namePropertyCSS variableDefaults to
Line 1Color--wst-system-line-1-color--wst-base-2-color
Line 1Width--wst-system-line-1-width
Line 2Color--wst-system-line-2-color--wst-accent-1-color
Line 2Width--wst-system-line-2-width

Fallback values

A var() fallback keeps your app rendering when a variable is unavailable. In this example, --wst-heading-1-color is a Harmony variable and #000000 is the fallback:

Copy

A custom element can run on any editor, and you can't control which one a site owner uses, so nest a second var() inside the fallback. An Editor React Component runs only on Harmony and doesn't need this. This example resolves --wst-heading-1-color on a Harmony site, falls back to the Wix Editor and Wix Studio variable --wst-color-title elsewhere, and falls back to black if neither exists:

Copy

The variables to nest are listed in Site Theme CSS Variables.

See also

Last updated: 6 August 2026

Did this help?