#311257#311257

#311257 is a dark, moderate violet. Relative luminance 0.018; OKLCH L 27.5% C 0.116 H 298.9°. Best body text is #FFFFFF at 15.50:1 contrast (WCAG AA passes).

Color values

HEX#311257
RGBrgb(49, 18, 87)
HSLhsl(267, 66%, 21%)
HSVhsv(267, 79%, 34%)
CMYKcmyk(43.7%, 79.3%, 0%, 65.9%)
CIE-LABlab(14.25, 31.10, -35.57)
CIE-LCHlch(14.25, 47.25, 311.17°)
OKLaboklab(27.47% 0.0562 -0.1016)
OKLCHoklch(27.47% 0.116 298.9)
XYZxyz(3.2028, 1.7737, 9.1886)
Luminance0.0177 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#311257 #385712
analogous
#121557 #311257 #531257
triadic
#311257 #573112 #125731
tetradic
#311257 #571215 #385712 #125753
square
#311257 #571215 #385712 #125753
split-complementary
#311257 #575312 #155712
monochromatic
#0E0519 #140824 #311257 #4E1C8A #6A27BC

Accessibility & contrast

On white

15.50
#311257 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.35
#311257 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #311257
15.50:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##311257#FFFFFF#000000##FFFFFF
##3112571.0015.501.3515.50
#FFFFFF15.501.0021.001.00
#0000001.3521.001.0021.00
##FFFFFF15.501.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002459
Deuteranopia (green-blind)
#002356
Tritanopia (blue-blind)
#282433
Achromatopsia (no color)
#242424

Design tokens & code

CSS
--color: #311257;
/* rgb */ color: rgb(49, 18, 87);
/* oklch */ color: oklch(27.5% 0.116 298.9);
Tailwind
colors: {
  custom: {
    50: '#6d5387',
    500: '#311257',
    950: '#000000',
  },
}
SCSS
$custom: #311257;
$custom-light: #6d5387;
$custom-dark: #000000;
JSON
{
  "hex": "#311257",
  "rgb": {
    "r": 49,
    "g": 18,
    "b": 87
  },
  "hsl": {
    "h": 266.957,
    "s": 65.714,
    "l": 20.588
  },
  "oklch": {
    "l": 0.27472,
    "c": 0.11611,
    "h": 298.9
  },
  "luminance": 0.01774
}

Semantic roles & 50–950 ramp

primary
#311257
secondary
#679035
accent
#E93F9C
background
#F6F4F8
surface
#ECE7EF
border
#C7C3CA
text
#07020B
muted
#7A787C

Preview Lab

Preview with #311257

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

Preview Lab → · Contrast checker → · Palette generator →

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