Skip to content

Color

Controls how color values are serialized wherever a Color appears in spec output — including solid fill and stroke styles, text color, shadow color, and gradient stops. By default, colors are emitted as compact hex strings, but you can switch to any CSS functional notation, Figma’s native HSB model, or a fully structured object that preserves the original color space without lossy conversion.

This is a formatting concern only — it doesn’t affect which colors are extracted or how they’re resolved from Figma. Token-bound colors are unaffected; format.color applies to literal, unbound color values.

Default

HEX

Values

OptionDescriptionExample
HEX6-digit hex string. Default — matches historical behaviour and maximises human readability#FF6600
HEXA8-digit hex string with alpha#FF6600FF
RGBCSS rgb() functional notationrgb(255, 102, 0)
RGBACSS rgba() functional notation with alpha. This is what Figma labels “CSS” in its colour pickerrgba(255, 102, 0, 1)
HSLACSS hsla() functional notationhsla(24, 100%, 50%, 1)
HSBFigma’s native colour model, also known as HSV. Not a CSS functionhsb(24, 100%, 100%)
OKLCHCSS Color Level 4 perceptually uniform cylindrical modeloklch(0.7 0.15 50 / 1)
OKLABCSS Color Level 4 perceptually uniform rectangular modeloklab(0.7 0.1 0.1 / 1)
OBJECTFull ColorObject with colorSpace, components, alpha, and optional hex. Preserves colour space fidelity with no lossy conversion

Path

config.format.color

Example

config:
format:
color: HEX # Default — 6-digit hex strings

See Also