#271172#271172

#271172 is a dark, vivid violet. Relative luminance 0.020; OKLCH L 29.1% C 0.151 H 282.1°. Best body text is #FFFFFF at 14.90:1 contrast (WCAG AA passes).

Color values

HEX#271172
RGBrgb(39, 17, 114)
HSLhsl(254, 74%, 26%)
HSVhsv(254, 85%, 45%)
CMYKcmyk(65.8%, 85.1%, 0%, 55.3%)
CIE-LABlab(15.73, 38.21, -51.04)
CIE-LCHlch(15.73, 63.76, 306.81°)
OKLaboklab(29.09% 0.0315 -0.1472)
OKLCHoklch(29.09% 0.151 282.1)
XYZxyz(4.0735, 2.0468, 16.0967)
Luminance0.0205 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#271172 #5C7211
analogous
#112B72 #271172 #571172
triadic
#271172 #722711 #117227
tetradic
#271172 #72112B #5C7211 #117257
square
#271172 #72112B #5C7211 #117257
split-complementary
#271172 #725711 #2B7211
monochromatic
#09041B #15093D #271172 #3919A7 #4B21DD

Accessibility & contrast

On white

14.90
#271172 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.41
#271172 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #271172
14.90:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##271172#FFFFFF#000000##FFFFFF
##2711721.0014.901.4114.90
#FFFFFF14.901.0021.001.00
#0000001.4121.001.0021.00
##FFFFFF14.901.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002A75
Deuteranopia (green-blind)
#002470
Tritanopia (blue-blind)
#002F42
Achromatopsia (no color)
#272727

Design tokens & code

CSS
--color: #271172;
/* rgb */ color: rgb(39, 17, 114);
/* oklch */ color: oklch(29.1% 0.151 282.1);
Tailwind
colors: {
  custom: {
    50: '#6d539c',
    500: '#271172',
    950: '#000000',
  },
}
SCSS
$custom: #271172;
$custom-light: #6d539c;
$custom-dark: #000000;
JSON
{
  "hex": "#271172",
  "rgb": {
    "r": 39,
    "g": 17,
    "b": 114
  },
  "hsl": {
    "h": 253.608,
    "s": 74.046,
    "l": 25.686
  },
  "oklch": {
    "l": 0.29087,
    "c": 0.15057,
    "h": 282.1
  },
  "luminance": 0.02047
}

Semantic roles & 50–950 ramp

primary
#271172
secondary
#8FA936
accent
#F137C7
background
#F7F4F9
surface
#EDE7F2
border
#C8C3CC
text
#08030E
muted
#7B787E

Preview Lab

Preview with #271172

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

Preview Lab → · Contrast checker → · Palette generator →

#271172 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva