#2B166F#2B166F

#2B166F is a dark, vivid violet. Relative luminance 0.022; OKLCH L 29.7% C 0.142 H 284.6°. Best body text is #FFFFFF at 14.51:1 contrast (WCAG AA passes).

Color values

HEX#2B166F
RGBrgb(43, 22, 111)
HSLhsl(254, 67%, 26%)
HSVhsv(254, 80%, 44%)
CMYKcmyk(61.3%, 80.2%, 0%, 56.5%)
CIE-LABlab(16.67, 35.25, -47.53)
CIE-LCHlch(16.67, 59.17, 306.56°)
OKLaboklab(29.74% 0.0358 -0.1369)
OKLCHoklch(29.74% 0.142 284.6)
XYZxyz(4.1515, 2.2348, 15.2484)
Luminance0.0223 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2B166F #5A6F16
analogous
#162D6F #2B166F #57166F
triadic
#2B166F #6F2B16 #166F2B
tetradic
#2B166F #6F162D #5A6F16 #166F57
square
#2B166F #6F162D #5A6F16 #166F57
split-complementary
#2B166F #6F5716 #2D6F16
monochromatic
#0A051A #170C3C #2B166F #3F20A2 #532BD5

Accessibility & contrast

On white

14.51
#2B166F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.45
#2B166F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2B166F
14.51:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2B166F#FFFFFF#000000##FFFFFF
##2B166F1.0014.511.4514.51
#FFFFFF14.511.0021.001.00
#0000001.4521.001.0021.00
##FFFFFF14.511.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002C72
Deuteranopia (green-blind)
#00266D
Tritanopia (blue-blind)
#043042
Achromatopsia (no color)
#292929

Design tokens & code

CSS
--color: #2b166f;
/* rgb */ color: rgb(43, 22, 111);
/* oklch */ color: oklch(29.7% 0.142 284.6);
Tailwind
colors: {
  custom: {
    50: '#6e5699',
    500: '#2b166f',
    950: '#000000',
  },
}
SCSS
$custom: #2b166f;
$custom-light: #6e5699;
$custom-dark: #000000;
JSON
{
  "hex": "#2b166f",
  "rgb": {
    "r": 43,
    "g": 22,
    "b": 111
  },
  "hsl": {
    "h": 254.157,
    "s": 66.917,
    "l": 26.078
  },
  "oklch": {
    "l": 0.29743,
    "c": 0.14152,
    "h": 284.6
  },
  "luminance": 0.02235
}

Semantic roles & 50–950 ramp

primary
#2B166F
secondary
#8CA53C
accent
#EA3EC1
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08030E
muted
#7B787E

Preview Lab

Preview with #2B166F

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

Preview Lab → · Contrast checker → · Palette generator →

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