#2B157C#2B157C

#2B157C is a dark, vivid violet. Relative luminance 0.025; OKLCH L 31.1% C 0.159 H 281.8°. Best body text is #FFFFFF at 13.99:1 contrast (WCAG AA passes).

Color values

HEX#2B157C
RGBrgb(43, 21, 124)
HSLhsl(253, 71%, 28%)
HSVhsv(253, 83%, 49%)
CMYKcmyk(65.3%, 83.1%, 0%, 51.4%)
CIE-LABlab(17.94, 39.81, -53.81)
CIE-LCHlch(17.94, 66.94, 306.50°)
OKLaboklab(31.06% 0.0323 -0.1552)
OKLCHoklch(31.06% 0.159 281.8)
XYZxyz(4.9014, 2.5048, 19.2901)
Luminance0.0250 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2B157C #667C15
analogous
#15327C #2B157C #5E157C
triadic
#2B157C #7C2B15 #157C2B
tetradic
#2B157C #7C1532 #667C15 #157C5E
square
#2B157C #7C1532 #667C15 #157C5E
split-complementary
#2B157C #7C5E15 #327C15
monochromatic
#09041A #190C48 #2B157C #3D1EB0 #5430DC

Accessibility & contrast

On white

13.99
#2B157C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.50
#2B157C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2B157C
13.99:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2B157C#FFFFFF#000000##FFFFFF
##2B157C1.0013.991.5013.99
#FFFFFF13.991.0021.001.00
#0000001.5021.001.0021.00
##FFFFFF13.991.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002F7F
Deuteranopia (green-blind)
#00287A
Tritanopia (blue-blind)
#003449
Achromatopsia (no color)
#2C2C2C

Design tokens & code

CSS
--color: #2b157c;
/* rgb */ color: rgb(43, 21, 124);
/* oklch */ color: oklch(31.1% 0.159 281.8);
Tailwind
colors: {
  custom: {
    50: '#7156a3',
    500: '#2b157c',
    950: '#000000',
  },
}
SCSS
$custom: #2b157c;
$custom-light: #7156a3;
$custom-dark: #000000;
JSON
{
  "hex": "#2b157c",
  "rgb": {
    "r": 43,
    "g": 21,
    "b": 124
  },
  "hsl": {
    "h": 252.816,
    "s": 71.034,
    "l": 28.431
  },
  "oklch": {
    "l": 0.31055,
    "c": 0.15857,
    "h": 281.8
  },
  "luminance": 0.02505
}

Semantic roles & 50–950 ramp

primary
#2B157C
secondary
#98B13C
accent
#EE3AC7
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#09030F
muted
#7B787F

Preview Lab

Preview with #2B157C

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

Preview Lab → · Contrast checker → · Palette generator →

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