#403181#403181

#403181 is a dark, vivid violet. Relative luminance 0.049; OKLCH L 37.7% C 0.129 H 287.1°. Best body text is #FFFFFF at 10.64:1 contrast (WCAG AA passes).

Color values

HEX#403181
RGBrgb(64, 49, 129)
HSLhsl(251, 45%, 35%)
HSVhsv(251, 62%, 51%)
CMYKcmyk(50.4%, 62%, 0%, 49.4%)
CIE-LABlab(26.36, 28.70, -43.11)
CIE-LCHlch(26.36, 51.79, 303.65°)
OKLaboklab(37.72% 0.038 -0.1233)
OKLCHoklch(37.72% 0.129 287.1)
XYZxyz(7.1740, 4.8713, 21.3269)
Luminance0.0487 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#403181 #728131
analogous
#314A81 #403181 #683181
triadic
#403181 #814031 #318140
tetradic
#403181 #81314A #728131 #318168
square
#403181 #81314A #728131 #318168
split-complementary
#403181 #816831 #4A8131
monochromatic
#140F28 #2A2055 #403181 #5642AD #7967C5

Accessibility & contrast

On white

10.64
#403181 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.97
#403181 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #403181
10.64:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##403181#FFFFFF#000000##FFFFFF
##4031811.0010.641.9710.64
#FFFFFF10.641.0021.001.00
#0000001.9721.001.0021.00
##FFFFFF10.641.0021.001.00

Color blindness preview

Protanopia (red-blind)
#004084
Deuteranopia (green-blind)
#003C7F
Tritanopia (blue-blind)
#2A4454
Achromatopsia (no color)
#3E3E3E

Design tokens & code

CSS
--color: #403181;
/* rgb */ color: rgb(64, 49, 129);
/* oklch */ color: oklch(37.7% 0.129 287.1);
Tailwind
colors: {
  custom: {
    50: '#7b6aa6',
    500: '#403181',
    950: '#000000',
  },
}
SCSS
$custom: #403181;
$custom-light: #7b6aa6;
$custom-dark: #000000;
JSON
{
  "hex": "#403181",
  "rgb": {
    "r": 64,
    "g": 49,
    "b": 129
  },
  "hsl": {
    "h": 251.25,
    "s": 44.944,
    "l": 34.902
  },
  "oklch": {
    "l": 0.37723,
    "c": 0.12902,
    "h": 287.1
  },
  "luminance": 0.04872
}

Semantic roles & 50–950 ramp

primary
#403181
secondary
#9FAD61
accent
#D553BC
background
#F7F6FA
surface
#EEEBF4
border
#C9C6CE
text
#0A060F
muted
#7C7A7F

Preview Lab

Preview with #403181

Body copy rendered with the generated semantic roles for this colour.

Preview Lab → · Contrast checker → · Palette generator →

#403181 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva