#2F176E#2F176E

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

Color values

HEX#2F176E
RGBrgb(47, 23, 110)
HSLhsl(257, 65%, 26%)
HSVhsv(257, 79%, 43%)
CMYKcmyk(57.3%, 79.1%, 0%, 56.9%)
CIE-LABlab(17.19, 34.99, -46.01)
CIE-LCHlch(17.19, 57.80, 307.25°)
OKLaboklab(30.18% 0.0418 -0.1324)
OKLCHoklch(30.18% 0.139 287.5)
XYZxyz(4.2923, 2.3427, 14.9748)
Luminance0.0234 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2F176E #566E17
analogous
#172A6E #2F176E #5A176E
triadic
#2F176E #6E2F17 #176E2F
tetradic
#2F176E #6E172A #566E17 #176E5A
square
#2F176E #6E172A #566E17 #176E5A
split-complementary
#2F176E #6E5A17 #2A6E17
monochromatic
#0B0519 #190C3B #2F176E #4522A1 #5A2CD3

Accessibility & contrast

On white

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

On black

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

Best text color

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

Contrast matrix

fg \ bg##2F176E#FFFFFF#000000##FFFFFF
##2F176E1.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)
#002C70
Deuteranopia (green-blind)
#00286C
Tritanopia (blue-blind)
#142F41
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #2f176e;
/* rgb */ color: rgb(47, 23, 110);
/* oklch */ color: oklch(30.2% 0.139 287.5);
Tailwind
colors: {
  custom: {
    50: '#705798',
    500: '#2f176e',
    950: '#000000',
  },
}
SCSS
$custom: #2f176e;
$custom-light: #705798;
$custom-dark: #000000;
JSON
{
  "hex": "#2f176e",
  "rgb": {
    "r": 47,
    "g": 23,
    "b": 110
  },
  "hsl": {
    "h": 256.552,
    "s": 65.414,
    "l": 26.078
  },
  "oklch": {
    "l": 0.30178,
    "c": 0.13882,
    "h": 287.5
  },
  "luminance": 0.02343
}

Semantic roles & 50–950 ramp

primary
#2F176E
secondary
#87A43D
accent
#E83FBA
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08030E
muted
#7B787E

Preview Lab

Preview with #2F176E

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

Preview Lab → · Contrast checker → · Palette generator →

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