ColorOverrides lets you override individual color tokens used across the checkout UI. You pass an instance to PrimerCheckoutTheme via its colors parameter.
Every property is an optional Color?. Any token you leave nil keeps the SDK’s internal default value. Light and dark appearances are resolved automatically by the SDK’s built-in design tokens, so a single override applies in both color schemes.
Override base tokens such as
primerColorBrand to recolor the whole UI in one change. Override semantic tokens (text, border, icon) only when you need a specific element to differ from what its base token resolves to.Brand and primary
Grays
Foundational neutral palette. Most semantic tokens (text, borders, icons) resolve from these.Semantic accents
Background and text
Border colors (outlined)
Applied to outlined inputs such as the card form fields, per interaction state.Border colors (transparent)
Used by elements with a transparent border surface, per interaction state.Icon colors
Utility
Overriding colors
Pass aColorOverrides instance into PrimerCheckoutTheme. Tokens you omit keep their SDK defaults.
primerColorBrand cascades to every semantic token that resolves from it (focus ring, loader, selected borders), so you can recolor the checkout with a single change.
See also
PrimerTheme
The container that bundles color, shape, spacing, and typography overrides.
Shape Tokens
Override corner radius and border width tokens.
Typography Tokens
Override font, size, weight, and line height per text style.
Spacing Tokens
Override spacing and size scale tokens.