#3B178D#3B178D

#3B178D is a dark, vivid violet. Relative luminance 0.035; OKLCH L 34.7% C 0.175 H 287.0°. Best body text is #FFFFFF at 12.40:1 contrast (WCAG AA passes).

Color values

HEX#3B178D
RGBrgb(59, 23, 141)
HSLhsl(258, 72%, 32%)
HSVhsv(258, 84%, 55%)
CMYKcmyk(58.2%, 83.7%, 0%, 44.7%)
CIE-LABlab(21.82, 45.73, -58.07)
CIE-LCHlch(21.82, 73.92, 308.22°)
OKLaboklab(34.7% 0.0512 -0.1672)
OKLCHoklch(34.7% 0.175 287)
XYZxyz(6.9163, 3.4653, 25.4986)
Luminance0.0347 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#3B178D #698D17
analogous
#172E8D #3B178D #76178D
triadic
#3B178D #8D3B17 #178D3B
tetradic
#3B178D #8D172E #698D17 #178D76
square
#3B178D #8D172E #698D17 #178D76
split-complementary
#3B178D #8D7617 #2E8D17
monochromatic
#0F0624 #250E58 #3B178D #5120C2 #703FE0

Accessibility & contrast

On white

12.40
#3B178D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.69
#3B178D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #3B178D
12.40:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##3B178D#FFFFFF#000000##FFFFFF
##3B178D1.0012.401.6912.40
#FFFFFF12.401.0021.001.00
#0000001.6921.001.0021.00
##FFFFFF12.401.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003790
Deuteranopia (green-blind)
#00318B
Tritanopia (blue-blind)
#133B53
Achromatopsia (no color)
#343434

Design tokens & code

CSS
--color: #3b178d;
/* rgb */ color: rgb(59, 23, 141);
/* oklch */ color: oklch(34.7% 0.175 287.0);
Tailwind
colors: {
  custom: {
    50: '#7c5ab0',
    500: '#3b178d',
    950: '#000000',
  },
}
SCSS
$custom: #3b178d;
$custom-light: #7c5ab0;
$custom-dark: #000000;
JSON
{
  "hex": "#3b178d",
  "rgb": {
    "r": 59,
    "g": 23,
    "b": 141
  },
  "hsl": {
    "h": 258.305,
    "s": 71.951,
    "l": 32.157
  },
  "oklch": {
    "l": 0.34698,
    "c": 0.17489,
    "h": 287
  },
  "luminance": 0.03466
}

Semantic roles & 50–950 ramp

primary
#3B178D
secondary
#99C040
accent
#EF39B7
background
#F8F5FA
surface
#EFE9F5
border
#CAC5CF
text
#0B0411
muted
#7C7980

Preview Lab

Preview with #3B178D

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

Preview Lab → · Contrast checker → · Palette generator →

#3B178D Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva