#2F186F#2F186F

#2F186F is a dark, vivid violet. Relative luminance 0.024; OKLCH L 30.4% C 0.139 H 287.0°. Best body text is #FFFFFF at 14.18:1 contrast (WCAG AA passes).

Color values

HEX#2F186F
RGBrgb(47, 24, 111)
HSLhsl(256, 64%, 26%)
HSVhsv(256, 78%, 44%)
CMYKcmyk(57.7%, 78.4%, 0%, 56.5%)
CIE-LABlab(17.48, 34.76, -46.18)
CIE-LCHlch(17.48, 57.80, 306.97°)
OKLaboklab(30.41% 0.0407 -0.1329)
OKLCHoklch(30.41% 0.139 287)
XYZxyz(4.3673, 2.4051, 15.2699)
Luminance0.0240 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2F186F #586F18
analogous
#182D6F #2F186F #5B186F
triadic
#2F186F #6F2F18 #186F2F
tetradic
#2F186F #6F182D #586F18 #186F5B
square
#2F186F #6F182D #586F18 #186F5B
split-complementary
#2F186F #6F5B18 #2D6F18
monochromatic
#0B0519 #1A0D3D #2F186F #4423A1 #5A2FD2

Accessibility & contrast

On white

14.18
#2F186F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.48
#2F186F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2F186F
14.18:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2F186F#FFFFFF#000000##FFFFFF
##2F186F1.0014.181.4814.18
#FFFFFF14.181.0021.001.00
#0000001.4821.001.0021.00
##FFFFFF14.181.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002D71
Deuteranopia (green-blind)
#00286D
Tritanopia (blue-blind)
#133042
Achromatopsia (no color)
#2B2B2B

Design tokens & code

CSS
--color: #2f186f;
/* rgb */ color: rgb(47, 24, 111);
/* oklch */ color: oklch(30.4% 0.139 287.0);
Tailwind
colors: {
  custom: {
    50: '#705899',
    500: '#2f186f',
    950: '#000000',
  },
}
SCSS
$custom: #2f186f;
$custom-light: #705899;
$custom-dark: #000000;
JSON
{
  "hex": "#2f186f",
  "rgb": {
    "r": 47,
    "g": 24,
    "b": 111
  },
  "hsl": {
    "h": 255.862,
    "s": 64.444,
    "l": 26.471
  },
  "oklch": {
    "l": 0.30414,
    "c": 0.13896,
    "h": 287
  },
  "luminance": 0.02405
}

Semantic roles & 50–950 ramp

primary
#2F186F
secondary
#8AA53E
accent
#E740BB
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08030E
muted
#7B787E

Preview Lab

Preview with #2F186F

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

Preview Lab → · Contrast checker → · Palette generator →

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