#381F8E#381F8E

#381F8E is a dark, vivid violet. Relative luminance 0.038; OKLCH L 35.4% C 0.169 H 284.0°. Best body text is #FFFFFF at 11.97:1 contrast (WCAG AA passes).

Color values

HEX#381F8E
RGBrgb(56, 31, 142)
HSLhsl(254, 64%, 34%)
HSVhsv(254, 78%, 56%)
CMYKcmyk(60.6%, 78.2%, 0%, 44.3%)
CIE-LABlab(22.91, 41.90, -56.91)
CIE-LCHlch(22.91, 70.67, 306.36°)
OKLaboklab(35.41% 0.0409 -0.164)
OKLCHoklch(35.41% 0.169 284)
XYZxyz(7.0019, 3.7733, 25.9453)
Luminance0.0377 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#381F8E #758E1F
analogous
#1F3D8E #381F8E #701F8E
triadic
#381F8E #8E381F #1F8E38
tetradic
#381F8E #8E1F3D #758E1F #1F8E70
square
#381F8E #8E1F3D #758E1F #1F8E70
split-complementary
#381F8E #8E701F #3D8E1F
monochromatic
#10092A #24145C #381F8E #4C2AC0 #6E4FD9

Accessibility & contrast

On white

11.97
#381F8E on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.75
#381F8E on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #381F8E
11.97:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##381F8E#FFFFFF#000000##FFFFFF
##381F8E1.0011.971.7511.97
#FFFFFF11.971.0021.001.00
#0000001.7521.001.0021.00
##FFFFFF11.971.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003A91
Deuteranopia (green-blind)
#00338C
Tritanopia (blue-blind)
#013F55
Achromatopsia (no color)
#373737

Design tokens & code

CSS
--color: #381f8e;
/* rgb */ color: rgb(56, 31, 142);
/* oklch */ color: oklch(35.4% 0.169 284.0);
Tailwind
colors: {
  custom: {
    50: '#7a5eb0',
    500: '#381f8e',
    950: '#000000',
  },
}
SCSS
$custom: #381f8e;
$custom-light: #7a5eb0;
$custom-dark: #000000;
JSON
{
  "hex": "#381f8e",
  "rgb": {
    "r": 56,
    "g": 31,
    "b": 142
  },
  "hsl": {
    "h": 253.514,
    "s": 64.162,
    "l": 33.922
  },
  "oklch": {
    "l": 0.3541,
    "c": 0.16904,
    "h": 284
  },
  "luminance": 0.03774
}

Semantic roles & 50–950 ramp

primary
#381F8E
secondary
#A3BB4D
accent
#E741C2
background
#F7F5FB
surface
#EEE9F6
border
#C9C5D0
text
#0A0511
muted
#7C7980

Preview Lab

Preview with #381F8E

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

Preview Lab → · Contrast checker → · Palette generator →

#381F8E Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva