#3A178F#3A178F

#3A178F is a dark, vivid violet. Relative luminance 0.035; OKLCH L 34.8% C 0.177 H 286.0°. Best body text is #FFFFFF at 12.36:1 contrast (WCAG AA passes).

Color values

HEX#3A178F
RGBrgb(58, 23, 143)
HSLhsl(258, 72%, 33%)
HSVhsv(258, 84%, 56%)
CMYKcmyk(59.4%, 83.9%, 0%, 43.9%)
CIE-LABlab(21.93, 46.18, -59.14)
CIE-LCHlch(21.93, 75.04, 307.99°)
OKLaboklab(34.81% 0.0489 -0.1704)
OKLCHoklch(34.81% 0.177 286)
XYZxyz(7.0077, 3.4951, 26.2866)
Luminance0.0350 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#3A178F #6C8F17
analogous
#17308F #3A178F #76178F
triadic
#3A178F #8F3A17 #178F3A
tetradic
#3A178F #8F1730 #6C8F17 #178F76
square
#3A178F #8F1730 #6C8F17 #178F76
split-complementary
#3A178F #8F7617 #308F17
monochromatic
#0F0626 #250F5A #3A178F #4F1FC4 #6F40E0

Accessibility & contrast

On white

12.36
#3A178F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.70
#3A178F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #3A178F
12.36:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##3A178F#FFFFFF#000000##FFFFFF
##3A178F1.0012.361.7012.36
#FFFFFF12.361.0021.001.00
#0000001.7021.001.0021.00
##FFFFFF12.361.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003792
Deuteranopia (green-blind)
#00318D
Tritanopia (blue-blind)
#0B3C54
Achromatopsia (no color)
#343434

Design tokens & code

CSS
--color: #3a178f;
/* rgb */ color: rgb(58, 23, 143);
/* oklch */ color: oklch(34.8% 0.177 286.0);
Tailwind
colors: {
  custom: {
    50: '#7c5ab1',
    500: '#3a178f',
    950: '#000000',
  },
}
SCSS
$custom: #3a178f;
$custom-light: #7c5ab1;
$custom-dark: #000000;
JSON
{
  "hex": "#3a178f",
  "rgb": {
    "r": 58,
    "g": 23,
    "b": 143
  },
  "hsl": {
    "h": 257.5,
    "s": 72.289,
    "l": 32.549
  },
  "oklch": {
    "l": 0.34811,
    "c": 0.17725,
    "h": 286
  },
  "luminance": 0.03496
}

Semantic roles & 50–950 ramp

primary
#3A178F
secondary
#9BC141
accent
#EF39BA
background
#F8F5FB
surface
#EFE9F6
border
#CAC5D0
text
#0B0411
muted
#7C7980

Preview Lab

Preview with #3A178F

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

Preview Lab → · Contrast checker → · Palette generator →

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