#331F90#331F90

#331F90 is a dark, vivid violet. Relative luminance 0.037; OKLCH L 35.2% C 0.172 H 280.9°. Best body text is #FFFFFF at 12.07:1 contrast (WCAG AA passes).

Color values

HEX#331F90
RGBrgb(51, 31, 144)
HSLhsl(251, 65%, 34%)
HSVhsv(251, 78%, 56%)
CMYKcmyk(64.6%, 78.5%, 0%, 43.5%)
CIE-LABlab(22.64, 41.89, -58.61)
CIE-LCHlch(22.64, 72.04, 305.56°)
OKLaboklab(35.17% 0.0327 -0.1691)
OKLCHoklch(35.17% 0.172 280.9)
XYZxyz(6.8877, 3.6969, 26.7308)
Luminance0.0370 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#331F90 #7C901F
analogous
#1F4490 #331F90 #6B1F90
triadic
#331F90 #90331F #1F9033
tetradic
#331F90 #901F44 #7C901F #1F906B
square
#331F90 #901F44 #7C901F #1F906B
split-complementary
#331F90 #906B1F #44901F
monochromatic
#0F092B #21145E #331F90 #452AC2 #6850D9

Accessibility & contrast

On white

12.07
#331F90 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.74
#331F90 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #331F90
12.07:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##331F90#FFFFFF#000000##FFFFFF
##331F901.0012.071.7412.07
#FFFFFF12.071.0021.001.00
#0000001.7421.001.0021.00
##FFFFFF12.071.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003A93
Deuteranopia (green-blind)
#00328E
Tritanopia (blue-blind)
#004057
Achromatopsia (no color)
#363636

Design tokens & code

CSS
--color: #331f90;
/* rgb */ color: rgb(51, 31, 144);
/* oklch */ color: oklch(35.2% 0.172 280.9);
Tailwind
colors: {
  custom: {
    50: '#785eb2',
    500: '#331f90',
    950: '#000000',
  },
}
SCSS
$custom: #331f90;
$custom-light: #785eb2;
$custom-dark: #000000;
JSON
{
  "hex": "#331f90",
  "rgb": {
    "r": 51,
    "g": 31,
    "b": 144
  },
  "hsl": {
    "h": 250.619,
    "s": 64.571,
    "l": 34.314
  },
  "oklch": {
    "l": 0.35172,
    "c": 0.17224,
    "h": 280.9
  },
  "luminance": 0.03697
}

Semantic roles & 50–950 ramp

primary
#331F90
secondary
#A9BC4E
accent
#E840CA
background
#F7F5FB
surface
#EEE9F6
border
#C9C5D0
text
#0A0411
muted
#7C7980

Preview Lab

Preview with #331F90

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

Preview Lab → · Contrast checker → · Palette generator →

#331F90 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva