#2D1F4E#2D1F4E

#2D1F4E is a dark, moderate violet. Relative luminance 0.021; OKLCH L 28.3% C 0.083 H 294.2°. Best body text is #FFFFFF at 14.81:1 contrast (WCAG AA passes).

Color values

HEX#2D1F4E
RGBrgb(45, 31, 78)
HSLhsl(258, 43%, 21%)
HSVhsv(258, 60%, 31%)
CMYKcmyk(42.3%, 60.3%, 0%, 69.4%)
CIE-LABlab(15.94, 19.40, -26.74)
CIE-LCHlch(15.94, 33.04, 305.95°)
OKLaboklab(28.34% 0.0341 -0.0759)
OKLCHoklch(28.34% 0.083 294.2)
XYZxyz(2.9470, 2.0879, 7.4540)
Luminance0.0209 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2D1F4E #404E1F
analogous
#1F294E #2D1F4E #451F4E
triadic
#2D1F4E #4E2D1F #1F4E2D
tetradic
#2D1F4E #4E1F29 #404E1F #1F4E45
square
#2D1F4E #4E1F29 #404E1F #1F4E45
split-complementary
#2D1F4E #4E451F #294E1F
monochromatic
#0D0916 #140E22 #2D1F4E #46307A #6042A6

Accessibility & contrast

On white

14.81
#2D1F4E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.42
#2D1F4E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2D1F4E
14.81:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2D1F4E#FFFFFF#000000##FFFFFF
##2D1F4E1.0014.811.4214.81
#FFFFFF14.811.0021.001.00
#0000001.4221.001.0021.00
##FFFFFF14.811.0021.001.00

Color blindness preview

Protanopia (red-blind)
#092850
Deuteranopia (green-blind)
#0D274D
Tritanopia (blue-blind)
#252933
Achromatopsia (no color)
#282828

Design tokens & code

CSS
--color: #2d1f4e;
/* rgb */ color: rgb(45, 31, 78);
/* oklch */ color: oklch(28.3% 0.083 294.2);
Tailwind
colors: {
  custom: {
    50: '#685b80',
    500: '#2d1f4e',
    950: '#000000',
  },
}
SCSS
$custom: #2d1f4e;
$custom-light: #685b80;
$custom-dark: #000000;
JSON
{
  "hex": "#2d1f4e",
  "rgb": {
    "r": 45,
    "g": 31,
    "b": 78
  },
  "hsl": {
    "h": 257.872,
    "s": 43.119,
    "l": 21.373
  },
  "oklch": {
    "l": 0.28343,
    "c": 0.08319,
    "h": 294.2
  },
  "luminance": 0.02088
}

Semantic roles & 50–950 ramp

primary
#2D1F4E
secondary
#718346
accent
#D355AD
background
#F6F5F7
surface
#EBE9EE
border
#C6C5C9
text
#06040A
muted
#7A797C

Preview Lab

Preview with #2D1F4E

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

Preview Lab → · Contrast checker → · Palette generator →

#2D1F4E Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva