#4B157E#4B157E

#4B157E is a dark, vivid violet. Relative luminance 0.035; OKLCH L 34.9% C 0.161 H 301.4°. Best body text is #FFFFFF at 12.30:1 contrast (WCAG AA passes).

Color values

HEX#4B157E
RGBrgb(75, 21, 126)
HSLhsl(271, 71%, 29%)
HSVhsv(271, 83%, 49%)
CMYKcmyk(40.5%, 83.3%, 0%, 50.6%)
CIE-LABlab(22.08, 44.78, -48.13)
CIE-LCHlch(22.08, 65.74, 312.94°)
OKLaboklab(34.88% 0.0839 -0.1375)
OKLCHoklch(34.88% 0.161 301.4)
XYZxyz(6.9348, 3.5385, 20.0523)
Luminance0.0354 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#4B157E #487E15
analogous
#16157E #4B157E #7E157D
triadic
#4B157E #7E4B15 #157E4B
tetradic
#4B157E #7E1615 #487E15 #157D7E
square
#4B157E #7E1615 #487E15 #157D7E
split-complementary
#4B157E #7D7E15 #157E16
monochromatic
#10041A #2C0C4A #4B157E #6A1EB2 #8931DD

Accessibility & contrast

On white

12.30
#4B157E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.71
#4B157E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #4B157E
12.30:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##4B157E#FFFFFF#000000##FFFFFF
##4B157E1.0012.301.7112.30
#FFFFFF12.301.0021.001.00
#0000001.7121.001.0021.00
##FFFFFF12.301.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003481
Deuteranopia (green-blind)
#00347C
Tritanopia (blue-blind)
#3F324A
Achromatopsia (no color)
#353535

Design tokens & code

CSS
--color: #4b157e;
/* rgb */ color: rgb(75, 21, 126);
/* oklch */ color: oklch(34.9% 0.161 301.4);
Tailwind
colors: {
  custom: {
    50: '#835aa4',
    500: '#4b157e',
    950: '#000000',
  },
}
SCSS
$custom: #4b157e;
$custom-light: #835aa4;
$custom-dark: #000000;
JSON
{
  "hex": "#4b157e",
  "rgb": {
    "r": 75,
    "g": 21,
    "b": 126
  },
  "hsl": {
    "h": 270.857,
    "s": 71.429,
    "l": 28.824
  },
  "oklch": {
    "l": 0.34883,
    "c": 0.16109,
    "h": 301.4
  },
  "luminance": 0.03539
}

Semantic roles & 50–950 ramp

primary
#4B157E
secondary
#76B33C
accent
#EE3A91
background
#F8F5FA
surface
#F0E9F4
border
#CBC5CE
text
#0B040F
muted
#7C797F

Preview Lab

Preview with #4B157E

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

Preview Lab → · Contrast checker → · Palette generator →

#4B157E Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva