#2B1172#2B1172

#2B1172 is a dark, vivid violet. Relative luminance 0.021; OKLCH L 29.5% C 0.150 H 284.7°. Best body text is #FFFFFF at 14.73:1 contrast (WCAG AA passes).

Color values

HEX#2B1172
RGBrgb(43, 17, 114)
HSLhsl(256, 74%, 26%)
HSVhsv(256, 85%, 45%)
CMYKcmyk(62.3%, 85.1%, 0%, 55.3%)
CIE-LABlab(16.15, 38.65, -50.34)
CIE-LCHlch(16.15, 63.46, 307.52°)
OKLaboklab(29.48% 0.0381 -0.1451)
OKLCHoklch(29.48% 0.15 284.7)
XYZxyz(4.2330, 2.1291, 16.1042)
Luminance0.0213 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2B1172 #587211
analogous
#112872 #2B1172 #5B1172
triadic
#2B1172 #722B11 #11722B
tetradic
#2B1172 #721128 #587211 #11725B
square
#2B1172 #721128 #587211 #11725B
split-complementary
#2B1172 #725B11 #287211
monochromatic
#0A041B #17093D #2B1172 #3F19A7 #5321DD

Accessibility & contrast

On white

14.73
#2B1172 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.43
#2B1172 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2B1172
14.73:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2B1172#FFFFFF#000000##FFFFFF
##2B11721.0014.731.4314.73
#FFFFFF14.731.0021.001.00
#0000001.4321.001.0021.00
##FFFFFF14.731.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002B75
Deuteranopia (green-blind)
#002570
Tritanopia (blue-blind)
#002F42
Achromatopsia (no color)
#282828

Design tokens & code

CSS
--color: #2b1172;
/* rgb */ color: rgb(43, 17, 114);
/* oklch */ color: oklch(29.5% 0.150 284.7);
Tailwind
colors: {
  custom: {
    50: '#6f549c',
    500: '#2b1172',
    950: '#000000',
  },
}
SCSS
$custom: #2b1172;
$custom-light: #6f549c;
$custom-dark: #000000;
JSON
{
  "hex": "#2b1172",
  "rgb": {
    "r": 43,
    "g": 17,
    "b": 114
  },
  "hsl": {
    "h": 256.082,
    "s": 74.046,
    "l": 25.686
  },
  "oklch": {
    "l": 0.29478,
    "c": 0.15,
    "h": 284.7
  },
  "luminance": 0.02129
}

Semantic roles & 50–950 ramp

primary
#2B1172
secondary
#8AA936
accent
#F137BF
background
#F7F5F9
surface
#EDE8F2
border
#C8C4CC
text
#08030E
muted
#7B787E

Preview Lab

Preview with #2B1172

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

Preview Lab → · Contrast checker → · Palette generator →

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