You are reading the development docs (2026.12.1-dev.1): features here may not be released yet.
Skip to content

Themes ​

A theme gives LCARdS cards their default colours, fonts and sizes as named tokens, such as colors.ui.primary, that the cards look up when they draw. It works alongside the HA-LCARS system theme: most colour tokens point at an HA-LCARS variable, with an LCARdS palette colour as the fallback.

  • Write theme: and a token path in a card's config, and the card takes that value from the active theme instead of a fixed colour.
  • LCARdS also adds its own --lcards-* colour palette to every page, so var(--lcards-orange) works with or without HA-LCARS.
  • Alert modes recolour both, so a card that uses theme tokens or palette colours changes with the alert level.

Find a token

The Config Panel's Theme Studio lists every token and CSS variable. A card editor's Main Engineering > Theme tab shows the tokens that card uses, with a button that copies the theme: reference.

Built-in Themes ​

lcards-default is the theme LCARdS loads at startup, and today the only one. Themes come in content packs, so new packs can change the look of every card at once.

  • The Pack Explorer shows every token a theme provides.
  • To change a single token without a new theme, use Token Overrides in the Theme Studio: for everyone, one user or one device.
ThemeDescription
lcards-defaultThe standard LCARS look, built on the HA-LCARS colours with LCARdS fallbacks

Using Theme Tokens ​

Write theme: and a token path as the whole value of a colour or size setting, and the card takes that value from the active theme. Use it for colours that should follow their role (structure, accent, alert) rather than a fixed shade.

  • In a text field's content, put the token in braces to write its value into the text: {theme:colors.ui.primary} is a token template. In a colour or size setting, write it without braces.
  • Inside a colour function the prefix is optional: alpha(colors.ui.primary, 0.4).
  • The config checker warns about a token path that doesn't exist and suggests the closest one.
yaml
type: custom:lcards-button
entity: light.demo
preset: lozenge
text:
  name:
    show: true
    color: theme:colors.text.onLight
style:
  card:
    color:
      background:
        active: theme:colors.ui.tertiary
        inactive: theme:colors.ui.quaternary
WriteWhereExample
theme:<path>The whole value of a colour or size settingcolor: theme:colors.ui.primary
{theme:<path>}Inside text, as a templatecontent: "SIZE {theme:typography.fontSize.base}"
<path>Inside a colour functionbackground: alpha(colors.ui.primary, 0.4)

Token Namespaces ​

Tokens are grouped by what they set: colours, type, borders, effects, and the defaults of each card. The Theme Studio lists them all; a card editor's Main Engineering > Theme tab lists the ones that card uses.

NamespaceWhat it holdsExample
colorsColours by role: text, ui, card, status, chart, alert, gridcolors.alert.red
typographyFont family, sizes, weights and text transformtypography.fontSize.base (14)
bordersBorder widths and corner radiiborders.radius.lg (8)
effectsOpacity steps for states such as inactive and unavailableeffects.opacity.inactive (0.7)
componentsEach card's own defaults: button, elbow, slider, chart, line, alert, dpad, backgroundAnimationcomponents.button.background.active

colors.ui ​

The four structure colours of an LCARS screen, by role. In lcards-default each takes the HA-LCARS theme colour, and falls back to an LCARdS palette colour without HA-LCARS.

Tokenlcards-default value
colors.ui.primaryvar(--lcars-ui-primary, var(--lcards-gray-medium))
colors.ui.secondaryvar(--lcars-ui-secondary, var(--lcards-gray-medium-light))
colors.ui.tertiaryvar(--lcars-ui-tertiary, var(--lcards-orange-medium-dark))
colors.ui.quaternaryvar(--lcars-ui-quaternary, var(--lcards-gray-dark))

LCARdS CSS Colour Palette ​

LCARdS adds --lcards-<colour>-<shade> CSS variables to every page at startup: five colour families of twelve names each, plus --lcards-moonlight. They work anywhere a CSS colour does, and don't need to be in your HA-LCARS theme.

  • The base colour has two names: --lcards-orange and --lcards-orange-medium are the same colour.
  • The colours below are the normal (green alert) values. In an alert mode every variable shifts with it, so you never change your references.
  • To follow the HA-LCARS theme where there is one, name its colour first and the palette as the fallback: var(--lcars-orange, var(--lcards-orange)).
yaml
type: custom:lcards-button
preset: lozenge
text:
  label:
    show: true
    content: PALETTE
    color: var(--lcards-blue-darkest)
style:
  card:
    color:
      background: var(--lcars-blue, var(--lcards-blue-light))
  border:
    color: var(--lcards-orange)
    width: 3

Orange ​

SwatchCSS variableToneHexNotes
--lcards-orange-darkest05#d91604Canon
--lcards-orange-1010#e01808Computed (interpolated)
--lcards-orange-dark20#ef1d10Canon
--lcards-orange-medium-dark30#e7442aCanon
--lcards-orange, --lcards-orange-medium40#ff6753Canon (base orange)
--lcards-orange-5050#ff715dComputed (interpolated)
--lcards-orange-6060#ff7b66Computed (interpolated)
--lcards-orange-medium-light70#ff8470Canon
--lcards-orange-light80#ff977bCanon
--lcards-orange-lightest90#ffb399Canon
--lcards-orange-9595#ffceb3Computed (extrapolated)

Gray ​

SwatchCSS variableToneHexNotes
--lcards-gray-darkest05#1e2229Canon
--lcards-gray-1010#232933Computed (interpolated)
--lcards-gray-dark20#2f3749Canon
--lcards-gray-medium-dark30#52596eCanon
--lcards-gray, --lcards-gray-medium40#6d748cCanon (base gray)
--lcards-gray-5050#7d849bComputed (interpolated)
--lcards-gray-6060#8d94aaComputed (interpolated)
--lcards-gray-medium-light70#9ea5baCanon
--lcards-gray-light80#d2d5dfCanon
--lcards-gray-lightest90#f3f4f7Canon
--lcards-gray-9595#f8f9fcComputed (extrapolated)
--lcards-moonlight-#dfe1e8Near-white, for text and labels (not part of the scale)

Blue ​

SwatchCSS variableToneHexNotes
--lcards-blue-darkest05#002241Canon
--lcards-blue-1010#082b48Computed (interpolated)
--lcards-blue-dark20#1c3c55Canon
--lcards-blue-medium-dark30#2a7193Canon
--lcards-blue, --lcards-blue-medium40#37a6d1Canon (base blue)
--lcards-blue-5050#48b2dbComputed (interpolated)
--lcards-blue-6060#58bee6Computed (interpolated)
--lcards-blue-medium-light70#67caf0Canon
--lcards-blue-light80#93e1ffCanon
--lcards-blue-lightest90#00eeeeCanon: an electric cyan accent, not a pale tint (see Shade Scale)
--lcards-blue-9595#44ffffComputed (extrapolated)

Green ​

SwatchCSS variableToneHexNotes
--lcards-green-darkest05#0c2a15Canon
--lcards-green-1010#0b2e16Computed (interpolated)
--lcards-green-dark20#083717Canon
--lcards-green-medium-dark30#095320Canon
--lcards-green, --lcards-green-medium40#266239Canon (base green)
--lcards-green-5050#306d43Computed (interpolated)
--lcards-green-6060#3b784eComputed (interpolated)
--lcards-green-medium-light70#458359Canon
--lcards-green-light80#80bb93Canon
--lcards-green-lightest90#b8e0c1Canon
--lcards-green-9595#cdf6d6Computed (extrapolated)

Yellow ​

SwatchCSS variableToneHexNotes
--lcards-yellow-darkest05#70602cCanon
--lcards-yellow-1010#847131Computed (interpolated)
--lcards-yellow-dark20#ac943bCanon
--lcards-yellow-medium-dark30#d2bf50Canon
--lcards-yellow, --lcards-yellow-medium40#f9ef97Canon (base yellow)
--lcards-yellow-5050#fbf3a8Computed (interpolated)
--lcards-yellow-6060#fdf6b9Computed (interpolated)
--lcards-yellow-medium-light70#fffac9Canon
--lcards-yellow-light80#e7e6deCanon: turns toward beige, not a smooth step (see Shade Scale)
--lcards-yellow-lightest90#f5f5dcCanon: warm white, cream
--lcards-yellow-9595#fbfbe2Computed (extrapolated)

Shade Scale ​

Each family has eleven shades, from darkest to lightest, matching the eleven tones of Home Assistant's own colour scale (--ha-color-<family>-05 to -95). The Tone column above says which tone a shade fills.

  • The seven canon shades have names: -darkest, -dark, -medium-dark, the base colour, -medium-light, -light and -lightest. They are the original hand-picked Picard-screen colours and are never changed.
  • The four computed shades in between have numbers only: -10, -50, -60 and -95. The canon shades have no numeric names: write --lcards-orange-dark, not --lcards-orange-20.
  • Not every family is a smooth ramp: blue's -lightest is a vivid electric cyan, and yellow's -light and -lightest turn toward parchment. These are choices in the canon palette, not slips in the computed shades.
ShadeToneOrigin
-darkest05Canon: the deepest, near-black tone
-1010Computed: between -darkest and -dark
-dark20Canon
-medium-dark30Canon
base, -medium40Canon: the core colour (--lcards-<colour>)
-5050Computed: between the base and -medium-light
-6060Computed: between the base and -medium-light
-medium-light70Canon
-light80Canon
-lightest90Canon: the palest of the original seven
-9595Computed: beyond -lightest
More about the computed shades
  • How they were made: in OKLCH colour space, anchored to the canon shades, so that Home Assistant's colour system gets the eleven steps it expects. scripts/generate-lcards-palette-scale.js generates them.
  • The palest step: -95 keeps the hue and chroma of -lightest and only moves the lightness toward white, rather than fading to white, because LCARS palettes stay vivid even at their palest.
  • Where they are used: the HA-LCARS LCARdS theme profiles map the whole scale onto Home Assistant's --ha-color-* tokens; see ha-css-vars.md.

HA-LCARS Theme Profiles ​

HA-LCARS includes two LCARdS theme profiles that use the --lcards-* palette as their single source of colour. They remap the HA-LCARS chrome variables and Home Assistant's own colour tokens (--ha-color-*), so stock Home Assistant components, LCARdS cards and the HA-LCARS chrome share one palette, alert-mode colour shifts included.

→ HA-LCARS Theme Profiles

Released under the MIT License. | About