#2F1276#2F1276

#2F1276 is a dark, vivid violet. Relative luminance 0.023; OKLCH L 30.4% C 0.153 H 286.2°. Best body text is #FFFFFF at 14.30:1 contrast (WCAG AA passes).

Color values

HEX#2F1276
RGBrgb(47, 18, 118)
HSLhsl(257, 74%, 27%)
HSVhsv(257, 85%, 46%)
CMYKcmyk(60.2%, 84.7%, 0%, 53.7%)
CIE-LABlab(17.20, 39.86, -51.17)
CIE-LCHlch(17.20, 64.86, 307.92°)
OKLaboklab(30.44% 0.0428 -0.1474)
OKLCHoklch(30.44% 0.153 286.2)
XYZxyz(4.6576, 2.3447, 17.3432)
Luminance0.0234 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2F1276 #597612
analogous
#122776 #2F1276 #611276
triadic
#2F1276 #762F12 #12762F
tetradic
#2F1276 #761227 #597612 #127661
square
#2F1276 #761227 #597612 #127661
split-complementary
#2F1276 #766112 #277612
monochromatic
#0B041B #1A0A41 #2F1276 #441AAB #5A25DE

Accessibility & contrast

On white

14.30
#2F1276 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #2F1276
14.30:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2F1276#FFFFFF#000000##FFFFFF
##2F12761.0014.301.4714.30
#FFFFFF14.301.0021.001.00
#0000001.4721.001.0021.00
##FFFFFF14.301.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002D79
Deuteranopia (green-blind)
#002774
Tritanopia (blue-blind)
#093145
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #2f1276;
/* rgb */ color: rgb(47, 18, 118);
/* oklch */ color: oklch(30.4% 0.153 286.2);
Tailwind
colors: {
  custom: {
    50: '#72559f',
    500: '#2f1276',
    950: '#000000',
  },
}
SCSS
$custom: #2f1276;
$custom-light: #72559f;
$custom-dark: #000000;
JSON
{
  "hex": "#2f1276",
  "rgb": {
    "r": 47,
    "g": 18,
    "b": 118
  },
  "hsl": {
    "h": 257.4,
    "s": 73.529,
    "l": 26.667
  },
  "oklch": {
    "l": 0.30443,
    "c": 0.15348,
    "h": 286.2
  },
  "luminance": 0.02345
}

Semantic roles & 50–950 ramp

primary
#2F1276
secondary
#8BAD37
accent
#F038BB
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#09030F
muted
#7B787E

Preview Lab

Preview with #2F1276

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

Preview Lab → · Contrast checker → · Palette generator →

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