#2C158F#2C158F

#2C158F is a dark, vivid violet. Relative luminance 0.031; OKLCH L 33.3% C 0.181 H 278.7°. Best body text is #FFFFFF at 13.04:1 contrast (WCAG AA passes).

Color values

HEX#2C158F
RGBrgb(44, 21, 143)
HSLhsl(251, 74%, 32%)
HSVhsv(251, 85%, 56%)
CMYKcmyk(69.2%, 85.3%, 0%, 43.9%)
CIE-LABlab(20.26, 45.66, -61.94)
CIE-LCHlch(20.26, 76.95, 306.39°)
OKLaboklab(33.33% 0.0275 -0.1789)
OKLCHoklch(33.33% 0.181 278.7)
XYZxyz(6.2632, 3.0544, 26.2408)
Luminance0.0306 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2C158F #788F15
analogous
#153B8F #2C158F #69158F
triadic
#2C158F #8F2C15 #158F2C
tetradic
#2C158F #8F153B #788F15 #158F69
square
#2C158F #8F153B #788F15 #158F69
split-complementary
#2C158F #8F6915 #3B8F15
monochromatic
#0B0524 #1C0D5A #2C158F #3C1DC4 #5B3CE2

Accessibility & contrast

On white

13.04
#2C158F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.61
#2C158F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2C158F
13.04:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2C158F#FFFFFF#000000##FFFFFF
##2C158F1.0013.041.6113.04
#FFFFFF13.041.0021.001.00
#0000001.6121.001.0021.00
##FFFFFF13.041.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003592
Deuteranopia (green-blind)
#002C8D
Tritanopia (blue-blind)
#003C54
Achromatopsia (no color)
#313131

Design tokens & code

CSS
--color: #2c158f;
/* rgb */ color: rgb(44, 21, 143);
/* oklch */ color: oklch(33.3% 0.181 278.7);
Tailwind
colors: {
  custom: {
    50: '#7558b1',
    500: '#2c158f',
    950: '#000000',
  },
}
SCSS
$custom: #2c158f;
$custom-light: #7558b1;
$custom-dark: #000000;
JSON
{
  "hex": "#2c158f",
  "rgb": {
    "r": 44,
    "g": 21,
    "b": 143
  },
  "hsl": {
    "h": 251.311,
    "s": 74.39,
    "l": 32.157
  },
  "oklch": {
    "l": 0.3333,
    "c": 0.18098,
    "h": 278.7
  },
  "luminance": 0.03055
}

Semantic roles & 50–950 ramp

primary
#2C158F
secondary
#A9C23E
accent
#F137CE
background
#F7F5FB
surface
#EEE9F6
border
#C9C5D0
text
#0A0411
muted
#7C7980

Preview Lab

Preview with #2C158F

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

Preview Lab → · Contrast checker → · Palette generator →

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