#40286F#40286F

#40286F is a dark, moderate violet. Relative luminance 0.038; OKLCH L 34.7% C 0.118 H 295.1°. Best body text is #FFFFFF at 11.99:1 contrast (WCAG AA passes).

Color values

HEX#40286F
RGBrgb(64, 40, 111)
HSLhsl(260, 47%, 30%)
HSVhsv(260, 64%, 44%)
CMYKcmyk(42.3%, 64%, 0%, 56.5%)
CIE-LABlab(22.84, 28.75, -37.36)
CIE-LCHlch(22.84, 47.14, 307.58°)
OKLaboklab(34.71% 0.05 -0.1064)
OKLCHoklch(34.71% 0.118 295.1)
XYZxyz(5.7416, 3.7551, 15.4582)
Luminance0.0376 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40286F #576F28
analogous
#28336F #40286F #64286F
triadic
#40286F #6F4028 #286F40
tetradic
#40286F #6F2833 #576F28 #286F64
square
#40286F #6F2833 #576F28 #286F64
split-complementary
#40286F #6F6428 #336F28
monochromatic
#0D0816 #261842 #40286F #5A389C #7751C0

Accessibility & contrast

On white

11.99
#40286F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.75
#40286F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #40286F
11.99:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40286F#FFFFFF#000000##FFFFFF
##40286F1.0011.991.7511.99
#FFFFFF11.991.0021.001.00
#0000001.7521.001.0021.00
##FFFFFF11.991.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003771
Deuteranopia (green-blind)
#03356D
Tritanopia (blue-blind)
#343847
Achromatopsia (no color)
#373737

Design tokens & code

CSS
--color: #40286f;
/* rgb */ color: rgb(64, 40, 111);
/* oklch */ color: oklch(34.7% 0.118 295.1);
Tailwind
colors: {
  custom: {
    50: '#796399',
    500: '#40286f',
    950: '#000000',
  },
}
SCSS
$custom: #40286f;
$custom-light: #796399;
$custom-dark: #000000;
JSON
{
  "hex": "#40286f",
  "rgb": {
    "r": 64,
    "g": 40,
    "b": 111
  },
  "hsl": {
    "h": 260.282,
    "s": 47.02,
    "l": 29.608
  },
  "oklch": {
    "l": 0.34713,
    "c": 0.11755,
    "h": 295.1
  },
  "luminance": 0.03755
}

Semantic roles & 50–950 ramp

primary
#40286F
secondary
#86A151
accent
#D751AA
background
#F7F5F9
surface
#EEEAF2
border
#C9C6CC
text
#09050E
muted
#7B797E

Preview Lab

Preview with #40286F

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

Preview Lab → · Contrast checker → · Palette generator →

#40286F Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva