#2D1771#2D1771

#2D1771 is a dark, vivid violet. Relative luminance 0.024; OKLCH L 30.3% C 0.143 H 285.3°. Best body text is #FFFFFF at 14.26:1 contrast (WCAG AA passes).

Color values

HEX#2D1771
RGBrgb(45, 23, 113)
HSLhsl(255, 66%, 27%)
HSVhsv(255, 80%, 44%)
CMYKcmyk(60.2%, 79.6%, 0%, 55.7%)
CIE-LABlab(17.29, 35.63, -47.81)
CIE-LCHlch(17.29, 59.62, 306.69°)
OKLaboklab(30.29% 0.0377 -0.1377)
OKLCHoklch(30.29% 0.143 285.3)
XYZxyz(4.3683, 2.3627, 15.8454)
Luminance0.0236 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2D1771 #5B7117
analogous
#172E71 #2D1771 #5A1771
triadic
#2D1771 #712D17 #17712D
tetradic
#2D1771 #71172E #5B7117 #17715A
square
#2D1771 #71172E #5B7117 #17715A
split-complementary
#2D1771 #715A17 #2E7117
monochromatic
#0A0519 #190D3E #2D1771 #4121A4 #572ED4

Accessibility & contrast

On white

14.26
#2D1771 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.47
#2D1771 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2D1771
14.26:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2D1771#FFFFFF#000000##FFFFFF
##2D17711.0014.261.4714.26
#FFFFFF14.261.0021.001.00
#0000001.4721.001.0021.00
##FFFFFF14.261.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002D74
Deuteranopia (green-blind)
#00286F
Tritanopia (blue-blind)
#093143
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #2d1771;
/* rgb */ color: rgb(45, 23, 113);
/* oklch */ color: oklch(30.3% 0.143 285.3);
Tailwind
colors: {
  custom: {
    50: '#6f579b',
    500: '#2d1771',
    950: '#000000',
  },
}
SCSS
$custom: #2d1771;
$custom-light: #6f579b;
$custom-dark: #000000;
JSON
{
  "hex": "#2d1771",
  "rgb": {
    "r": 45,
    "g": 23,
    "b": 113
  },
  "hsl": {
    "h": 254.667,
    "s": 66.176,
    "l": 26.667
  },
  "oklch": {
    "l": 0.30287,
    "c": 0.14276,
    "h": 285.3
  },
  "luminance": 0.02363
}

Semantic roles & 50–950 ramp

primary
#2D1771
secondary
#8DA73D
accent
#E93FBF
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08030E
muted
#7B787E

Preview Lab

Preview with #2D1771

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

Preview Lab → · Contrast checker → · Palette generator →

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