#40226E#40226E
#40226E is a dark, vivid violet. Relative luminance 0.034; OKLCH L 33.7% C 0.125 H 297.3°. Best body text is #FFFFFF at 12.56:1 contrast (WCAG AA passes).
Color values
| HEX | #40226E |
|---|---|
| RGB | rgb(64, 34, 110) |
| HSL | hsl(264, 53%, 28%) |
| HSV | hsv(264, 69%, 43%) |
| CMYK | cmyk(41.8%, 69.1%, 0%, 56.9%) |
| CIE-LAB | lab(21.43, 32.06, -39.00) |
| CIE-LCH | lch(21.43, 50.49, 309.42°) |
| OKLab | oklab(33.66% 0.0575 -0.1112) |
| OKLCH | oklch(33.66% 0.125 297.3) |
| XYZ | xyz(5.5001, 3.3597, 15.1075) |
| Luminance | 0.0336 (WCAG relative) |
| Temperature | cool |
| Family | violet |
Closest named colors
Royal Purple (survey)
#4B006E
ΔE00 6.11
Indigo
#4B0082
ΔE00 6.61
Midnight Blue
#191970
ΔE00 6.64
Indigo (survey)
#380282
ΔE00 6.98
Dark Indigo
#1F0954
ΔE00 7.62
Darkslateblue
#483D8B
ΔE00 8.34
Perceptual scales
Shades
Tints
Tones
OKLCH scale
Color harmonies
complementary
#40226E #506E22
analogous
#222A6E #40226E #66226E
triadic
#40226E #6E4022 #226E40
tetradic
#40226E #6E222A #506E22 #226E66
square
#40226E #6E222A #506E22 #226E66
split-complementary
#40226E #6E6622 #2A6E22
monochromatic
#0E0717 #25143F #40226E #5B309D #7845C5
Accessibility & contrast
On white
12.56
#40226E on #FFFFFF
AA ✓AA large ✓AAA ✓
On black
1.67
#40226E on #000000
AA ✗AA large ✗AAA ✗
Best text color
#FFFFFF on #40226E
12.56:1 — WCAG AA (normal text) passes
Contrast matrix
| fg \ bg | ##40226E | #FFFFFF | #000000 | ##FFFFFF |
|---|---|---|---|---|
| ##40226E | 1.00 | 12.56 | 1.67 | 12.56 |
| #FFFFFF | 12.56 | 1.00 | 21.00 | 1.00 |
| #000000 | 1.67 | 21.00 | 1.00 | 21.00 |
| ##FFFFFF | 12.56 | 1.00 | 21.00 | 1.00 |
Color blindness preview
Protanopia (red-blind)
#003470
Deuteranopia (green-blind)
#00336C
Tritanopia (blue-blind)
#353445
Achromatopsia (no color)
#333333
Design tokens & code
CSS
--color: #40226e; /* rgb */ color: rgb(64, 34, 110); /* oklch */ color: oklch(33.7% 0.125 297.3);
Tailwind
colors: {
custom: {
50: '#795f98',
500: '#40226e',
950: '#000000',
},
}SCSS
$custom: #40226e; $custom-light: #795f98; $custom-dark: #000000;
JSON
{
"hex": "#40226e",
"rgb": {
"r": 64,
"g": 34,
"b": 110
},
"hsl": {
"h": 263.684,
"s": 52.778,
"l": 28.235
},
"oklch": {
"l": 0.33663,
"c": 0.12521,
"h": 297.3
},
"luminance": 0.0336
}Semantic roles & 50–950 ramp
primary
#40226E
secondary
#7FA14A
accent
#DC4CA3
background
#F7F5F9
surface
#EEE9F2
border
#C9C5CC
text
#09050E
muted
#7B797E