#2D157D#2D157D

#2D157D is a dark, vivid violet. Relative luminance 0.026; OKLCH L 31.4% C 0.159 H 282.7°. Best body text is #FFFFFF at 13.86:1 contrast (WCAG AA passes).

Color values

HEX#2D157D
RGBrgb(45, 21, 125)
HSLhsl(254, 71%, 29%)
HSVhsv(254, 83%, 49%)
CMYKcmyk(64%, 83.2%, 0%, 51%)
CIE-LABlab(18.25, 40.34, -53.93)
CIE-LCHlch(18.25, 67.35, 306.80°)
OKLaboklab(31.35% 0.0352 -0.1555)
OKLCHoklch(31.35% 0.159 282.7)
XYZxyz(5.0509, 2.5745, 19.6288)
Luminance0.0257 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2D157D #657D15
analogous
#15317D #2D157D #61157D
triadic
#2D157D #7D2D15 #157D2D
tetradic
#2D157D #7D1531 #657D15 #157D61
square
#2D157D #7D1531 #657D15 #157D61
split-complementary
#2D157D #7D6115 #317D15
monochromatic
#09041A #1A0C49 #2D157D #401EB1 #5830DC

Accessibility & contrast

On white

13.86
#2D157D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.52
#2D157D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2D157D
13.86:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2D157D#FFFFFF#000000##FFFFFF
##2D157D1.0013.861.5213.86
#FFFFFF13.861.0021.001.00
#0000001.5221.001.0021.00
##FFFFFF13.861.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003080
Deuteranopia (green-blind)
#00297B
Tritanopia (blue-blind)
#00354A
Achromatopsia (no color)
#2D2D2D

Design tokens & code

CSS
--color: #2d157d;
/* rgb */ color: rgb(45, 21, 125);
/* oklch */ color: oklch(31.4% 0.159 282.7);
Tailwind
colors: {
  custom: {
    50: '#7257a4',
    500: '#2d157d',
    950: '#000000',
  },
}
SCSS
$custom: #2d157d;
$custom-light: #7257a4;
$custom-dark: #000000;
JSON
{
  "hex": "#2d157d",
  "rgb": {
    "r": 45,
    "g": 21,
    "b": 125
  },
  "hsl": {
    "h": 253.846,
    "s": 71.233,
    "l": 28.627
  },
  "oklch": {
    "l": 0.31353,
    "c": 0.15946,
    "h": 282.7
  },
  "luminance": 0.02575
}

Semantic roles & 50–950 ramp

primary
#2D157D
secondary
#97B23C
accent
#EE3AC4
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#09030F
muted
#7B787F

Preview Lab

Preview with #2D157D

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

Preview Lab → · Contrast checker → · Palette generator →

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