#2F1F71#2F1F71

#2F1F71 is a dark, vivid violet. Relative luminance 0.028; OKLCH L 31.6% C 0.133 H 284.8°. Best body text is #FFFFFF at 13.50:1 contrast (WCAG AA passes).

Color values

HEX#2F1F71
RGBrgb(47, 31, 113)
HSLhsl(252, 57%, 28%)
HSVhsv(252, 73%, 44%)
CMYKcmyk(58.4%, 72.6%, 0%, 55.7%)
CIE-LABlab(19.12, 31.36, -44.78)
CIE-LCHlch(19.12, 54.67, 305.01°)
OKLaboklab(31.64% 0.034 -0.1288)
OKLCHoklch(31.64% 0.133 284.8)
XYZxyz(4.6420, 2.7763, 15.9109)
Luminance0.0278 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2F1F71 #61711F
analogous
#1F3871 #2F1F71 #581F71
triadic
#2F1F71 #712F1F #1F712F
tetradic
#2F1F71 #711F38 #61711F #1F7158
square
#2F1F71 #711F38 #61711F #1F7158
split-complementary
#2F1F71 #71581F #38711F
monochromatic
#0A0718 #1B1241 #2F1F71 #432CA1 #5B40CB

Accessibility & contrast

On white

13.50
#2F1F71 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.56
#2F1F71 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2F1F71
13.50:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2F1F71#FFFFFF#000000##FFFFFF
##2F1F711.0013.501.5613.50
#FFFFFF13.501.0021.001.00
#0000001.5621.001.0021.00
##FFFFFF13.501.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003173
Deuteranopia (green-blind)
#002C6F
Tritanopia (blue-blind)
#103445
Achromatopsia (no color)
#2E2E2E

Design tokens & code

CSS
--color: #2f1f71;
/* rgb */ color: rgb(47, 31, 113);
/* oklch */ color: oklch(31.6% 0.133 284.8);
Tailwind
colors: {
  custom: {
    50: '#6f5c9b',
    500: '#2f1f71',
    950: '#000000',
  },
}
SCSS
$custom: #2f1f71;
$custom-light: #6f5c9b;
$custom-dark: #000000;
JSON
{
  "hex": "#2f1f71",
  "rgb": {
    "r": 47,
    "g": 31,
    "b": 113
  },
  "hsl": {
    "h": 251.707,
    "s": 56.944,
    "l": 28.235
  },
  "oklch": {
    "l": 0.31639,
    "c": 0.13323,
    "h": 284.8
  },
  "luminance": 0.02777
}

Semantic roles & 50–950 ramp

primary
#2F1F71
secondary
#93A547
accent
#E048C2
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08040E
muted
#7B797E

Preview Lab

Preview with #2F1F71

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

Preview Lab → · Contrast checker → · Palette generator →

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