#2F1B8E#2F1B8E

#2F1B8E is a dark, vivid violet. Relative luminance 0.033; OKLCH L 34.1% C 0.174 H 279.8°. Best body text is #FFFFFF at 12.59:1 contrast (WCAG AA passes).

Color values

HEX#2F1B8E
RGBrgb(47, 27, 142)
HSLhsl(250, 68%, 33%)
HSVhsv(250, 81%, 56%)
CMYKcmyk(66.9%, 81%, 0%, 44.3%)
CIE-LABlab(21.36, 42.86, -59.49)
CIE-LCHlch(21.36, 73.32, 305.77°)
OKLaboklab(34.12% 0.0295 -0.1718)
OKLCHoklch(34.12% 0.174 279.8)
XYZxyz(6.4452, 3.3407, 25.8911)
Luminance0.0334 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2F1B8E #7A8E1B
analogous
#1B408E #2F1B8E #681B8E
triadic
#2F1B8E #8E2F1B #1B8E2F
tetradic
#2F1B8E #8E1B40 #7A8E1B #1B8E68
square
#2F1B8E #8E1B40 #7A8E1B #1B8E68
split-complementary
#2F1B8E #8E681B #408E1B
monochromatic
#0D0727 #1E115B #2F1B8E #4025C1 #6147DC

Accessibility & contrast

On white

12.59
#2F1B8E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.67
#2F1B8E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2F1B8E
12.59:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2F1B8E#FFFFFF#000000##FFFFFF
##2F1B8E1.0012.591.6712.59
#FFFFFF12.591.0021.001.00
#0000001.6721.001.0021.00
##FFFFFF12.591.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003791
Deuteranopia (green-blind)
#002F8C
Tritanopia (blue-blind)
#003E55
Achromatopsia (no color)
#333333

Design tokens & code

CSS
--color: #2f1b8e;
/* rgb */ color: rgb(47, 27, 142);
/* oklch */ color: oklch(34.1% 0.174 279.8);
Tailwind
colors: {
  custom: {
    50: '#765bb0',
    500: '#2f1b8e',
    950: '#000000',
  },
}
SCSS
$custom: #2f1b8e;
$custom-light: #765bb0;
$custom-dark: #000000;
JSON
{
  "hex": "#2f1b8e",
  "rgb": {
    "r": 47,
    "g": 27,
    "b": 142
  },
  "hsl": {
    "h": 250.435,
    "s": 68.047,
    "l": 33.137
  },
  "oklch": {
    "l": 0.34122,
    "c": 0.17429,
    "h": 279.8
  },
  "luminance": 0.03341
}

Semantic roles & 50–950 ramp

primary
#2F1B8E
secondary
#A9BE47
accent
#EB3DCD
background
#F7F5FB
surface
#EEE9F6
border
#C9C5D0
text
#0A0411
muted
#7C7980

Preview Lab

Preview with #2F1B8E

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

Preview Lab → · Contrast checker → · Palette generator →

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