Brand gradient
Figma gradient
The gradient Figma's published colour tokens imply, derived by a pure function of the palette: primary → secondary in OKLab (OKLCH shorter hue when the hues are more than 140° apart; a tonal ramp when they are within ΔE 0.15), then a hero background with an ink that passes AA at the worst point along the line, a button surface with hover and active states, and the variant contact sheet. Same inputs, same gradients, forever — which is what makes them citable; the same values are served as --brand-gradient in the brand's brand.css.
- Source
- figma.com
- Extracted
- Version
- 3
Hero and button
Hero background
Open in maker →Chroma ×0.35 so it can carry text; ink white (inkFor at the midpoint). L shifted −0.11 until the ink passes AA at the worst point (4.61:1).
linear-gradient(135deg in oklch shorter hue, #955e4f 0%, #56789a 100%)
bg-linear-to-br/oklch from-[#955e4f] to-[#56789a]
Button / CTA
Open in maker →ΔL 0.08 top→bottom in the primary's hue (a lit surface, not a rainbow); hover L +0.03, active L −0.03. L shifted −0.10 so white ink gets as close as the ±0.1 bound allows to AA on the surface and both states (worst 4.03:1). Ink is below AA (4.03:1 at the worst point) — use it for large text only, or pick a darker/lighter primary for buttons.
linear-gradient(180deg in oklch shorter hue, #dc3800 0%, #bf1000 100%)
bg-linear-to-b/oklch from-[#dc3800] to-[#bf1000]
Variants
Tonal ramp
Open in maker →linear-gradient(135deg in oklch shorter hue, #ffaa90 0%, #f24e1e 50%, #ac0800 100%)
bg-linear-to-br/oklch from-[#ffaa90] via-[#f24e1e] to-[#ac0800]
Analogous
Open in maker →Partner hue from the analogous rule at the source colour's lightness.
linear-gradient(135deg in oklab, #f24e1e 0%, #f93079 100%)
bg-linear-to-br/oklab from-[#f24e1e] to-[#f93079]
Complementary
Open in maker →Partner hue from the complementary rule at the source colour's lightness. ΔH 179° > 140° — interpolating in oklch (shorter hue) keeps the midpoint saturated.
linear-gradient(135deg in oklch shorter hue, #f24e1e 0%, #249eb8 100%)
bg-linear-to-br/oklch from-[#f24e1e] to-[#249eb8]
Triadic
Open in maker →Partner hue from the triadic rule at the source colour's lightness.
linear-gradient(135deg in oklab, #f24e1e 0%, #24a867 100%)
bg-linear-to-br/oklab from-[#f24e1e] to-[#24a867]
Report — brand gradient
- white ink: worst 2.99:1 at 100% (fails AA); black ink: worst 5.86:1 at 1% (AA) → use black text.
- Banding medium: ~6px bands at 1440px — add grain 11 (≈1% soft-light noise) or shorten the ramp.
- 5/64 samples left sRGB by more than 5% and were gamut-mapped (oklch shorter); expect slight hue drift there.
Export
The custom properties below are byte-identical to the gradient block in brand.css; the DTCG token is what tokens.json carries.
:root {
/* Brand gradient (derived) */
/* worst-case contrast: white 2.99:1, black 5.86:1 AA */
--brand-gradient: linear-gradient(135deg in oklch shorter hue, #f24e1e 0%, #0d99ff 100%);
/* hero — worst-case contrast: white 4.61:1 AA, black 3.99:1 AA-large; ink passes AA at the worst point */
--brand-gradient-hero: linear-gradient(135deg in oklch shorter hue, #955e4f 0%, #56789a 100%);
--brand-gradient-hero-ink: #ffffff;
/* button — worst-case contrast: white 4.56:1 AA, black 3.29:1 AA-large */
--brand-gradient-button: linear-gradient(180deg in oklch shorter hue, #dc3800 0%, #bf1000 100%);
--brand-gradient-button-hover: linear-gradient(180deg in oklch shorter hue, #e7430d 0%, #ca2100 100%);
--brand-gradient-button-active: linear-gradient(180deg in oklch shorter hue, #d12b00 0%, #b10a00 100%);
--brand-gradient-button-ink: #ffffff;
/* button ink: 4.0:1 — below AA */
}<svg xmlns="http://www.w3.org/2000/svg" width="1440" height="600" viewBox="0 0 1440 600"><defs><linearGradient id="bs-gradient" gradientUnits="userSpaceOnUse" x1="210" y1="-210" x2="1230" y2="810"><stop offset="0%" stop-color="#f24e1e"/><stop offset="7.14%" stop-color="#f34a49"/><stop offset="14.29%" stop-color="#f24967"/><stop offset="21.43%" stop-color="#ee4a81"/><stop offset="28.57%" stop-color="#e74e99"/><stop offset="35.71%" stop-color="#df53b0"/><stop offset="42.86%" stop-color="#d45ac4"/><stop offset="50%" stop-color="#c860d6"/><stop offset="57.14%" stop-color="#b968e6"/><stop offset="64.29%" stop-color="#a970f3"/><stop offset="71.43%" stop-color="#9778fd"/><stop offset="78.57%" stop-color="#8280ff"/><stop offset="85.71%" stop-color="#6989ff"/><stop offset="92.86%" stop-color="#4a91ff"/><stop offset="100%" stop-color="#0d99ff"/></linearGradient></defs><rect width="1440" height="600" fill="url(#bs-gradient)"/></svg>
{
"gradient": {
"brand": {
"$type": "gradient",
"$value": [
{
"color": {
"colorSpace": "srgb",
"components": [
0.949,
0.306,
0.118
],
"hex": "#f24e1e"
},
"position": 0
},
{
"color": {
"colorSpace": "srgb",
"components": [
0.051,
0.6,
1
],
"hex": "#0d99ff"
},
"position": 1
}
],
"$extensions": {
"com.brandsweets": {
"kind": "linear",
"css": "linear-gradient(135deg in oklch shorter hue, #f24e1e 0%, #0d99ff 100%)",
"interpolation": "oklch",
"hue": "shorter",
"angle": 135,
"name": "brand",
"contrast": {
"white": {
"ratio": 2.992,
"at": 1,
"passesAA": false,
"passesAALarge": false
},
"black": {
"ratio": 5.862,
"at": 0.0077,
"passesAA": true,
"passesAALarge": true
},
"suggestedInk": "#000000"
}
}
},
"$description": "The canonical brand gradient (--brand-gradient)."
},
"hero": {
"$type": "gradient",
"$value": [
{
"color": {
"colorSpace": "srgb",
"components": [
0.584,
0.369,
0.31
],
"hex": "#955e4f"
},
"position": 0
},
{
"color": {
"colorSpace": "srgb",
"components": [
0.337,
0.471,
0.604
],
"hex": "#56789a"
},
"position": 1
}
],
"$extensions": {
"com.brandsweets": {
"kind": "linear",
"css": "linear-gradient(135deg in oklch shorter hue, #955e4f 0%, #56789a 100%)",
"interpolation": "oklch",
"hue": "shorter",
"angle": 135,
"name": "hero",
"ink": "#ffffff",
"contrast": {
"white": {
"ratio": 4.607,
"at": 0.9947,
"passesAA": true,
"passesAALarge": true
},
"black": {
"ratio": 3.991,
"at": 0.0442,
"passesAA": false,
"passesAALarge": true
},
"suggestedInk": "#ffffff"
}
}
},
"$description": "Low-chroma hero background with a text-safe ink (--brand-gradient-hero)."
},
"button": {
"$type": "gradient",
"$value": [
{
"color": {
"colorSpace": "srgb",
"components": [
0.863,
0.22,
0
],
"hex": "#dc3800"
},
"position": 0
},
{
"color": {
"colorSpace": "srgb",
"components": [
0.749,
0.063,
0
],
"hex": "#bf1000"
},
"position": 1
}
],
"$extensions": {
"com.brandsweets": {
"kind": "linear",
"css": "linear-gradient(180deg in oklch shorter hue, #dc3800 0%, #bf1000 100%)",
"interpolation": "oklch",
"hue": "shorter",
"angle": 180,
"name": "button",
"ink": "#ffffff",
"states": {
"hover": "linear-gradient(180deg in oklch shorter hue, #e7430d 0%, #ca2100 100%)",
"active": "linear-gradient(180deg in oklch shorter hue, #d12b00 0%, #b10a00 100%)"
},
"contrast": {
"white": {
"ratio": 4.557,
"at": 0,
"passesAA": true,
"passesAALarge": true
},
"black": {
"ratio": 3.289,
"at": 1,
"passesAA": false,
"passesAALarge": true
},
"suggestedInk": "#ffffff"
}
}
},
"$description": "Button / CTA surface with hover and active states (--brand-gradient-button)."
}
}
}Colours
Point any MCP client at the shared gradients endpoint and your agent gets the same engine as this page — make_gradient returns CSS with the interpolation space, Tailwind v4, SVG, a PNG URL, a DTCG token and the contrast report in one call; brand_gradients derives the whole contact sheet from a brand or a palette. Read-only, no key. Every gradient is a /gradients/new/… link: open it, refine, paste it back.
https://mcp.brandsweets.com/gradients/mcpclaude mcp add --transport http brandsweets-gradients https://mcp.brandsweets.com/gradients/mcp
›brand_gradients for figma — give me the hero CSS and the ink that passes AA, then a version in oklch
Want the agent to remember your picks and write them into a living brand? Create a free BrandSweets workspace.
Figma and its marks belong to their owner. This page uses the name nominatively to describe gradients derived from the brand's published colour values; it does not reproduce logos or other brand assets, and it is not affiliated with or endorsed by Figma. Owner of this brand? Request a correction or removal → Machine-readable: gradients.md