#311F81#311F81
#311F81 is a dark, vivid violet. Relative luminance 0.032; OKLCH L 33.4% C 0.154 H 282.6°. Best body text is #FFFFFF at 12.78:1 contrast (WCAG AA passes).
Color values
| HEX | #311F81 |
|---|---|
| RGB | rgb(49, 31, 129) |
| HSL | hsl(251, 61%, 31%) |
| HSV | hsv(251, 76%, 51%) |
| CMYK | cmyk(62%, 76%, 0%, 49.4%) |
| CIE-LAB | lab(20.89, 36.89, -52.10) |
| CIE-LCH | lch(20.89, 63.83, 305.30°) |
| OKLab | oklab(33.43% 0.0336 -0.1502) |
| OKLCH | oklch(33.43% 0.154 282.6) |
| XYZ | xyz(5.7178, 3.2175, 21.0844) |
| Luminance | 0.0322 (WCAG relative) |
| Temperature | cool |
| Family | violet |
Closest named colors
Midnight Blue
#191970
ΔE00 3.98
Royal
#0C1793
ΔE00 4.38
Indigo (survey)
#380282
ΔE00 4.84
Indigo
#4B0082
ΔE00 6.33
Darkblue
#00008B
ΔE00 6.34
Navy
#000080
ΔE00 6.52
Perceptual scales
Shades
Tints
Tones
OKLCH scale
Color harmonies
complementary
#311F81 #6F811F
analogous
#1F3E81 #311F81 #621F81
triadic
#311F81 #81311F #1F8131
tetradic
#311F81 #811F3E #6F811F #1F8162
square
#311F81 #811F3E #6F811F #1F8162
split-complementary
#311F81 #81621F #3E811F
monochromatic
#0C071E #1E1350 #311F81 #442BB2 #6147D3
Accessibility & contrast
On white
12.78
#311F81 on #FFFFFF
AA ✓AA large ✓AAA ✓
On black
1.64
#311F81 on #000000
AA ✗AA large ✗AAA ✗
Best text color
#FFFFFF on #311F81
12.78:1 — WCAG AA (normal text) passes
Contrast matrix
| fg \ bg | ##311F81 | #FFFFFF | #000000 | ##FFFFFF |
|---|---|---|---|---|
| ##311F81 | 1.00 | 12.78 | 1.64 | 12.78 |
| #FFFFFF | 12.78 | 1.00 | 21.00 | 1.00 |
| #000000 | 1.64 | 21.00 | 1.00 | 21.00 |
| ##FFFFFF | 12.78 | 1.00 | 21.00 | 1.00 |
Color blindness preview
Protanopia (red-blind)
#003584
Deuteranopia (green-blind)
#002F7F
Tritanopia (blue-blind)
#003A4E
Achromatopsia (no color)
#323232
Design tokens & code
CSS
--color: #311f81; /* rgb */ color: rgb(49, 31, 129); /* oklch */ color: oklch(33.4% 0.154 282.6);
Tailwind
colors: {
custom: {
50: '#745da7',
500: '#311f81',
950: '#000000',
},
}SCSS
$custom: #311f81; $custom-light: #745da7; $custom-dark: #000000;
JSON
{
"hex": "#311f81",
"rgb": {
"r": 49,
"g": 31,
"b": 129
},
"hsl": {
"h": 251.02,
"s": 61.25,
"l": 31.373
},
"oklch": {
"l": 0.33426,
"c": 0.15387,
"h": 282.6
},
"luminance": 0.03218
}Semantic roles & 50–950 ramp
primary
#311F81
secondary
#A0B448
accent
#E443C7
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#09040F
muted
#7B797F