#271B57#271B57

#271B57 is a dark, moderate violet. Relative luminance 0.019; OKLCH L 27.7% C 0.103 H 286.8°. Best body text is #FFFFFF at 15.21:1 contrast (WCAG AA passes).

Color values

HEX#271B57
RGBrgb(39, 27, 87)
HSLhsl(252, 53%, 22%)
HSVhsv(252, 69%, 34%)
CMYKcmyk(55.2%, 69%, 0%, 65.9%)
CIE-LABlab(14.97, 23.61, -34.45)
CIE-LCHlch(14.97, 41.76, 304.42°)
OKLaboklab(27.7% 0.0298 -0.0988)
OKLCHoklch(27.7% 0.103 286.8)
XYZxyz(2.9484, 1.9032, 9.2270)
Luminance0.0190 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#271B57 #4B571B
analogous
#1B2D57 #271B57 #451B57
triadic
#271B57 #57271B #1B5727
tetradic
#271B57 #571B2D #4B571B #1B5745
square
#271B57 #571B2D #4B571B #1B5745
split-complementary
#271B57 #57451B #2D571B
monochromatic
#0A0717 #120D28 #271B57 #3C2986 #5138B4

Accessibility & contrast

On white

15.21
#271B57 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.38
#271B57 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #271B57
15.21:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##271B57#FFFFFF#000000##FFFFFF
##271B571.0015.211.3815.21
#FFFFFF15.211.0021.001.00
#0000001.3821.001.0021.00
##FFFFFF15.211.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002759
Deuteranopia (green-blind)
#002456
Tritanopia (blue-blind)
#152A36
Achromatopsia (no color)
#262626

Design tokens & code

CSS
--color: #271b57;
/* rgb */ color: rgb(39, 27, 87);
/* oklch */ color: oklch(27.7% 0.103 286.8);
Tailwind
colors: {
  custom: {
    50: '#665887',
    500: '#271b57',
    950: '#000000',
  },
}
SCSS
$custom: #271b57;
$custom-light: #665887;
$custom-dark: #000000;
JSON
{
  "hex": "#271b57",
  "rgb": {
    "r": 39,
    "g": 27,
    "b": 87
  },
  "hsl": {
    "h": 252,
    "s": 52.632,
    "l": 22.353
  },
  "oklch": {
    "l": 0.27702,
    "c": 0.10316,
    "h": 286.8
  },
  "luminance": 0.01903
}

Semantic roles & 50–950 ramp

primary
#271B57
secondary
#7E8D41
accent
#DC4CBF
background
#F6F5F8
surface
#EBE9EF
border
#C6C5CA
text
#06030B
muted
#7A787C

Preview Lab

Preview with #271B57

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

Preview Lab → · Contrast checker → · Palette generator →

#271B57 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva