#2F176B#2F176B

#2F176B is a dark, vivid violet. Relative luminance 0.023; OKLCH L 29.9% C 0.135 H 288.4°. Best body text is #FFFFFF at 14.43:1 contrast (WCAG AA passes).

Color values

HEX#2F176B
RGBrgb(47, 23, 107)
HSLhsl(257, 65%, 25%)
HSVhsv(257, 79%, 42%)
CMYKcmyk(56.1%, 78.5%, 0%, 58%)
CIE-LABlab(16.89, 34.06, -44.56)
CIE-LCHlch(16.89, 56.08, 307.39°)
OKLaboklab(29.87% 0.0427 -0.1281)
OKLCHoklch(29.87% 0.135 288.4)
XYZxyz(4.1317, 2.2785, 14.1291)
Luminance0.0228 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2F176B #536B17
analogous
#17296B #2F176B #59176B
triadic
#2F176B #6B2F17 #176B2F
tetradic
#2F176B #6B1729 #536B17 #176B59
square
#2F176B #6B1729 #536B17 #176B59
split-complementary
#2F176B #6B5917 #296B17
monochromatic
#0B0519 #190C39 #2F176B #45229D #5B2DD0

Accessibility & contrast

On white

14.43
#2F176B on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.46
#2F176B on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2F176B
14.43:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2F176B#FFFFFF#000000##FFFFFF
##2F176B1.0014.431.4614.43
#FFFFFF14.431.0021.001.00
#0000001.4621.001.0021.00
##FFFFFF14.431.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002B6D
Deuteranopia (green-blind)
#002769
Tritanopia (blue-blind)
#172E40
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #2f176b;
/* rgb */ color: rgb(47, 23, 107);
/* oklch */ color: oklch(29.9% 0.135 288.4);
Tailwind
colors: {
  custom: {
    50: '#6f5796',
    500: '#2f176b',
    950: '#000000',
  },
}
SCSS
$custom: #2f176b;
$custom-light: #6f5796;
$custom-dark: #000000;
JSON
{
  "hex": "#2f176b",
  "rgb": {
    "r": 47,
    "g": 23,
    "b": 107
  },
  "hsl": {
    "h": 257.143,
    "s": 64.615,
    "l": 25.49
  },
  "oklch": {
    "l": 0.2987,
    "c": 0.13503,
    "h": 288.4
  },
  "luminance": 0.02279
}

Semantic roles & 50–950 ramp

primary
#2F176B
secondary
#84A13D
accent
#E840B8
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08030D
muted
#7B787E

Preview Lab

Preview with #2F176B

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

Preview Lab → · Contrast checker → · Palette generator →

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