#38178E#38178E

#38178E is a dark, vivid violet. Relative luminance 0.034; OKLCH L 34.5% C 0.176 H 285.1°. Best body text is #FFFFFF at 12.49:1 contrast (WCAG AA passes).

Color values

HEX#38178E
RGBrgb(56, 23, 142)
HSLhsl(257, 72%, 32%)
HSVhsv(257, 84%, 56%)
CMYKcmyk(60.6%, 83.8%, 0%, 44.3%)
CIE-LABlab(21.60, 45.68, -59.06)
CIE-LCHlch(21.60, 74.67, 307.72°)
OKLaboklab(34.5% 0.046 -0.1702)
OKLCHoklch(34.5% 0.176 285.1)
XYZxyz(6.8183, 3.4061, 25.8841)
Luminance0.0341 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#38178E #6D8E17
analogous
#17318E #38178E #74178E
triadic
#38178E #8E3817 #178E38
tetradic
#38178E #8E1731 #6D8E17 #178E74
square
#38178E #8E1731 #6D8E17 #178E74
split-complementary
#38178E #8E7417 #318E17
monochromatic
#0E0625 #230E59 #38178E #4D20C3 #6C3FE0

Accessibility & contrast

On white

12.49
#38178E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.68
#38178E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #38178E
12.49:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##38178E#FFFFFF#000000##FFFFFF
##38178E1.0012.491.6812.49
#FFFFFF12.491.0021.001.00
#0000001.6821.001.0021.00
##FFFFFF12.491.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003791
Deuteranopia (green-blind)
#00308C
Tritanopia (blue-blind)
#023C54
Achromatopsia (no color)
#343434

Design tokens & code

CSS
--color: #38178e;
/* rgb */ color: rgb(56, 23, 142);
/* oklch */ color: oklch(34.5% 0.176 285.1);
Tailwind
colors: {
  custom: {
    50: '#7a5ab0',
    500: '#38178e',
    950: '#000000',
  },
}
SCSS
$custom: #38178e;
$custom-light: #7a5ab0;
$custom-dark: #000000;
JSON
{
  "hex": "#38178e",
  "rgb": {
    "r": 56,
    "g": 23,
    "b": 142
  },
  "hsl": {
    "h": 256.639,
    "s": 72.121,
    "l": 32.353
  },
  "oklch": {
    "l": 0.34504,
    "c": 0.17631,
    "h": 285.1
  },
  "luminance": 0.03407
}

Semantic roles & 50–950 ramp

primary
#38178E
secondary
#9DC040
accent
#EF39BC
background
#F8F5FB
surface
#EFE9F6
border
#CAC5D0
text
#0A0411
muted
#7C7980

Preview Lab

Preview with #38178E

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

Preview Lab → · Contrast checker → · Palette generator →

#38178E Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva