#310F5F#310F5F

#310F5F is a dark, vivid violet. Relative luminance 0.018; OKLCH L 27.9% C 0.129 H 296.0°. Best body text is #FFFFFF at 15.39:1 contrast (WCAG AA passes).

Color values

HEX#310F5F
RGBrgb(49, 15, 95)
HSLhsl(266, 73%, 22%)
HSVhsv(266, 84%, 37%)
CMYKcmyk(48.4%, 84.2%, 0%, 62.7%)
CIE-LABlab(14.52, 34.85, -40.51)
CIE-LCHlch(14.52, 53.43, 310.70°)
OKLaboklab(27.9% 0.0566 -0.1161)
OKLCHoklch(27.9% 0.129 296)
XYZxyz(3.5025, 1.8208, 10.9912)
Luminance0.0182 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#310F5F #3D5F0F
analogous
#0F155F #310F5F #590F5F
triadic
#310F5F #5F310F #0F5F31
tetradic
#310F5F #5F0F15 #3D5F0F #0F5F59
square
#310F5F #5F0F15 #3D5F0F #0F5F59
split-complementary
#310F5F #5F590F #155F0F
monochromatic
#0E041A #16072A #310F5F #4C1794 #6820C9

Accessibility & contrast

On white

15.39
#310F5F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.36
#310F5F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #310F5F
15.39:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##310F5F#FFFFFF#000000##FFFFFF
##310F5F1.0015.391.3615.39
#FFFFFF15.391.0021.001.00
#0000001.3621.001.0021.00
##FFFFFF15.391.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002561
Deuteranopia (green-blind)
#00245E
Tritanopia (blue-blind)
#242537
Achromatopsia (no color)
#252525

Design tokens & code

CSS
--color: #310f5f;
/* rgb */ color: rgb(49, 15, 95);
/* oklch */ color: oklch(27.9% 0.129 296.0);
Tailwind
colors: {
  custom: {
    50: '#6f528d',
    500: '#310f5f',
    950: '#000000',
  },
}
SCSS
$custom: #310f5f;
$custom-light: #6f528d;
$custom-dark: #000000;
JSON
{
  "hex": "#310f5f",
  "rgb": {
    "r": 49,
    "g": 15,
    "b": 95
  },
  "hsl": {
    "h": 265.5,
    "s": 72.727,
    "l": 21.569
  },
  "oklch": {
    "l": 0.27898,
    "c": 0.12918,
    "h": 296
  },
  "luminance": 0.01821
}

Semantic roles & 50–950 ramp

primary
#310F5F
secondary
#6D9832
accent
#EF38A2
background
#F7F4F8
surface
#EDE7F0
border
#C8C3CB
text
#08020C
muted
#7B787D

Preview Lab

Preview with #310F5F

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

Preview Lab → · Contrast checker → · Palette generator →

#310F5F Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva