#381F98#381F98

#381F98 is a dark, vivid violet. Relative luminance 0.041; OKLCH L 36.5% C 0.181 H 282.1°. Best body text is #FFFFFF at 11.55:1 contrast (WCAG AA passes).

Color values

HEX#381F98
RGBrgb(56, 31, 152)
HSLhsl(252, 66%, 36%)
HSVhsv(252, 80%, 60%)
CMYKcmyk(63.2%, 79.6%, 0%, 40.4%)
CIE-LABlab(23.96, 44.93, -61.36)
CIE-LCHlch(23.96, 76.05, 306.21°)
OKLaboklab(36.46% 0.038 -0.177)
OKLCHoklch(36.46% 0.181 282.1)
XYZxyz(7.7866, 4.0872, 30.0783)
Luminance0.0409 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#381F98 #7F981F
analogous
#1F4298 #381F98 #741F98
triadic
#381F98 #98381F #1F9838
tetradic
#381F98 #981F42 #7F981F #1F9874
square
#381F98 #981F42 #7F981F #1F9874
split-complementary
#381F98 #98741F #42981F
monochromatic
#130A32 #251565 #381F98 #4B29CB #7155DC

Accessibility & contrast

On white

11.55
#381F98 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.82
#381F98 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #381F98
11.55:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##381F98#FFFFFF#000000##FFFFFF
##381F981.0011.551.8211.55
#FFFFFF11.551.0021.001.00
#0000001.8221.001.0021.00
##FFFFFF11.551.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003D9B
Deuteranopia (green-blind)
#003596
Tritanopia (blue-blind)
#00435B
Achromatopsia (no color)
#393939

Design tokens & code

CSS
--color: #381f98;
/* rgb */ color: rgb(56, 31, 152);
/* oklch */ color: oklch(36.5% 0.181 282.1);
Tailwind
colors: {
  custom: {
    50: '#7c5fb8',
    500: '#381f98',
    950: '#000000',
  },
}
SCSS
$custom: #381f98;
$custom-light: #7c5fb8;
$custom-dark: #000000;
JSON
{
  "hex": "#381f98",
  "rgb": {
    "r": 56,
    "g": 31,
    "b": 152
  },
  "hsl": {
    "h": 252.397,
    "s": 66.12,
    "l": 35.882
  },
  "oklch": {
    "l": 0.36458,
    "c": 0.18104,
    "h": 282.1
  },
  "luminance": 0.04088
}

Semantic roles & 50–950 ramp

primary
#381F98
secondary
#A9C053
accent
#E93FC6
background
#F8F5FB
surface
#EFE9F6
border
#CAC5D0
text
#0B0511
muted
#7C7980

Preview Lab

Preview with #381F98

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

Preview Lab → · Contrast checker → · Palette generator →

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