#311F8A#311F8A
#311F8A is a dark, vivid violet. Relative luminance 0.035; OKLCH L 34.4% C 0.165 H 280.9°. Best body text is #FFFFFF at 12.40:1 contrast (WCAG AA passes).
Color values
| HEX | #311F8A |
|---|---|
| RGB | rgb(49, 31, 138) |
| HSL | hsl(250, 63%, 33%) |
| HSV | hsv(250, 78%, 54%) |
| CMYK | cmyk(64.5%, 77.5%, 0%, 45.9%) |
| CIE-LAB | lab(21.83, 39.76, -56.22) |
| CIE-LCH | lch(21.83, 68.86, 305.27°) |
| OKLab | oklab(34.36% 0.0313 -0.1622) |
| OKLCH | oklch(34.36% 0.165 280.9) |
| XYZ | xyz(6.3426, 3.4674, 24.3749) |
| Luminance | 0.0347 (WCAG relative) |
| Temperature | cool |
| Family | violet |
Closest named colors
Royal
#0C1793
ΔE00 3.55
Indigo (survey)
#380282
ΔE00 4.84
Midnight Blue
#191970
ΔE00 4.94
Cobalt Blue
#030AA7
ΔE00 5.57
Indigo Blue
#3A18B1
ΔE00 5.69
Darkblue
#00008B
ΔE00 5.98
Perceptual scales
Shades
Tints
Tones
OKLCH scale
Color harmonies
complementary
#311F8A #788A1F
analogous
#1F438A #311F8A #661F8A
triadic
#311F8A #8A311F #1F8A31
tetradic
#311F8A #8A1F43 #788A1F #1F8A66
square
#311F8A #8A1F43 #788A1F #1F8A66
split-complementary
#311F8A #8A661F #438A1F
monochromatic
#0E0926 #1F1458 #311F8A #432ABC #644CD7
Accessibility & contrast
On white
12.40
#311F8A on #FFFFFF
AA ✓AA large ✓AAA ✓
On black
1.69
#311F8A on #000000
AA ✗AA large ✗AAA ✗
Best text color
#FFFFFF on #311F8A
12.40:1 — WCAG AA (normal text) passes
Contrast matrix
| fg \ bg | ##311F8A | #FFFFFF | #000000 | ##FFFFFF |
|---|---|---|---|---|
| ##311F8A | 1.00 | 12.40 | 1.69 | 12.40 |
| #FFFFFF | 12.40 | 1.00 | 21.00 | 1.00 |
| #000000 | 1.69 | 21.00 | 1.00 | 21.00 |
| ##FFFFFF | 12.40 | 1.00 | 21.00 | 1.00 |
Color blindness preview
Protanopia (red-blind)
#00388D
Deuteranopia (green-blind)
#003088
Tritanopia (blue-blind)
#003E53
Achromatopsia (no color)
#343434
Design tokens & code
CSS
--color: #311f8a; /* rgb */ color: rgb(49, 31, 138); /* oklch */ color: oklch(34.4% 0.165 280.9);
Tailwind
colors: {
custom: {
50: '#765dad',
500: '#311f8a',
950: '#000000',
},
}SCSS
$custom: #311f8a; $custom-light: #765dad; $custom-dark: #000000;
JSON
{
"hex": "#311f8a",
"rgb": {
"r": 49,
"g": 31,
"b": 138
},
"hsl": {
"h": 250.093,
"s": 63.314,
"l": 33.137
},
"oklch": {
"l": 0.34364,
"c": 0.16521,
"h": 280.9
},
"luminance": 0.03468
}Semantic roles & 50–950 ramp
primary
#311F8A
secondary
#A7BA4B
accent
#E641CB
background
#F7F5FA
surface
#EEE9F4
border
#C9C5CE
text
#090410
muted
#7B797F