#2F186D#2F186D

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

Color values

HEX#2F186D
RGBrgb(47, 24, 109)
HSLhsl(256, 64%, 26%)
HSVhsv(256, 78%, 43%)
CMYKcmyk(56.9%, 78%, 0%, 57.3%)
CIE-LABlab(17.28, 34.14, -45.21)
CIE-LCHlch(17.28, 56.65, 307.05°)
OKLaboklab(30.21% 0.0412 -0.13)
OKLCHoklch(30.21% 0.136 287.6)
XYZxyz(4.2584, 2.3615, 14.6965)
Luminance0.0236 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2F186D #566D18
analogous
#182B6D #2F186D #59186D
triadic
#2F186D #6D2F18 #186D2F
tetradic
#2F186D #6D182B #566D18 #186D59
square
#2F186D #6D182B #566D18 #186D59
split-complementary
#2F186D #6D5918 #2B6D18
monochromatic
#0B0619 #190D3B #2F186D #45239F #5A2ED1

Accessibility & contrast

On white

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

On black

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

Best text color

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

Contrast matrix

fg \ bg##2F186D#FFFFFF#000000##FFFFFF
##2F186D1.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)
#002C6F
Deuteranopia (green-blind)
#00286B
Tritanopia (blue-blind)
#152F41
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #2f186d;
/* rgb */ color: rgb(47, 24, 109);
/* oklch */ color: oklch(30.2% 0.136 287.6);
Tailwind
colors: {
  custom: {
    50: '#6f5898',
    500: '#2f186d',
    950: '#000000',
  },
}
SCSS
$custom: #2f186d;
$custom-light: #6f5898;
$custom-dark: #000000;
JSON
{
  "hex": "#2f186d",
  "rgb": {
    "r": 47,
    "g": 24,
    "b": 109
  },
  "hsl": {
    "h": 256.235,
    "s": 63.91,
    "l": 26.078
  },
  "oklch": {
    "l": 0.30209,
    "c": 0.13642,
    "h": 287.6
  },
  "luminance": 0.02362
}

Semantic roles & 50–950 ramp

primary
#2F186D
secondary
#87A33E
accent
#E741BA
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08030E
muted
#7B787E

Preview Lab

Preview with #2F186D

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

Preview Lab → · Contrast checker → · Palette generator →

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