IT lexicon › Web › CSS variables

CSS variables Custom Properties

Web På svenska → Updated: 2026-05-24

Variables straight in CSS: --primary: #4a8, used with color: var(--primary).

Unlike Sass variables, CSS variables are dynamic — can be changed via JS, inherit through the cascade, respect scope. The force behind modern theme/dark-mode implementations.

← Back to the lexicon