#2F156A#2F156A

#2F156A is a dark, vivid violet. Relative luminance 0.022; OKLCH L 29.5% C 0.136 H 289.2°. Best body text is #FFFFFF at 14.62:1 contrast (WCAG AA passes).

Color values

HEX#2F156A
RGBrgb(47, 21, 106)
HSLhsl(258, 67%, 25%)
HSVhsv(258, 80%, 42%)
CMYKcmyk(55.7%, 80.2%, 0%, 58.4%)
CIE-LABlab(16.41, 34.81, -44.68)
CIE-LCHlch(16.41, 56.64, 307.92°)
OKLaboklab(29.51% 0.0447 -0.1285)
OKLCHoklch(29.51% 0.136 289.2)
XYZxyz(4.0412, 2.1811, 13.8409)
Luminance0.0218 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2F156A #506A15
analogous
#15266A #2F156A #5A156A
triadic
#2F156A #6A2F15 #156A2F
tetradic
#2F156A #6A1526 #506A15 #156A5A
square
#2F156A #6A1526 #506A15 #156A5A
split-complementary
#2F156A #6A5A15 #266A15
monochromatic
#0B051A #180B37 #2F156A #461F9D #5C29D0

Accessibility & contrast

On white

14.62
#2F156A on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.44
#2F156A on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2F156A
14.62:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2F156A#FFFFFF#000000##FFFFFF
##2F156A1.0014.621.4414.62
#FFFFFF14.621.0021.001.00
#0000001.4421.001.0021.00
##FFFFFF14.621.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002A6C
Deuteranopia (green-blind)
#002768
Tritanopia (blue-blind)
#182D3F
Achromatopsia (no color)
#292929

Design tokens & code

CSS
--color: #2f156a;
/* rgb */ color: rgb(47, 21, 106);
/* oklch */ color: oklch(29.5% 0.136 289.2);
Tailwind
colors: {
  custom: {
    50: '#6f5695',
    500: '#2f156a',
    950: '#000000',
  },
}
SCSS
$custom: #2f156a;
$custom-light: #6f5695;
$custom-dark: #000000;
JSON
{
  "hex": "#2f156a",
  "rgb": {
    "r": 47,
    "g": 21,
    "b": 106
  },
  "hsl": {
    "h": 258.353,
    "s": 66.929,
    "l": 24.902
  },
  "oklch": {
    "l": 0.29505,
    "c": 0.136,
    "h": 289.2
  },
  "luminance": 0.02181
}

Semantic roles & 50–950 ramp

primary
#2F156A
secondary
#81A13A
accent
#EA3EB5
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08030D
muted
#7B787E

Preview Lab

Preview with #2F156A

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

Preview Lab → · Contrast checker → · Palette generator →

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