#3F1271#3F1271

#3F1271 is a dark, vivid violet. Relative luminance 0.027; OKLCH L 31.8% C 0.148 H 298.8°. Best body text is #FFFFFF at 13.67:1 contrast (WCAG AA passes).

Color values

HEX#3F1271
RGBrgb(63, 18, 113)
HSLhsl(268, 73%, 26%)
HSVhsv(268, 84%, 44%)
CMYKcmyk(44.2%, 84.1%, 0%, 55.7%)
CIE-LABlab(18.72, 40.72, -45.37)
CIE-LCHlch(18.72, 60.96, 311.90°)
OKLaboklab(31.8% 0.0713 -0.1299)
OKLCHoklch(31.8% 0.148 298.8)
XYZxyz(5.2461, 2.6815, 15.8608)
Luminance0.0268 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#3F1271 #447112
analogous
#121471 #3F1271 #6E1271
triadic
#3F1271 #713F12 #12713F
tetradic
#3F1271 #711214 #447112 #12716E
square
#3F1271 #711214 #447112 #12716E
split-complementary
#3F1271 #716E12 #147112
monochromatic
#0F041A #220A3C #3F1271 #5C1AA6 #7A23DB

Accessibility & contrast

On white

13.67
#3F1271 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.54
#3F1271 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #3F1271
13.67:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##3F1271#FFFFFF#000000##FFFFFF
##3F12711.0013.671.5413.67
#FFFFFF13.671.0021.001.00
#0000001.5421.001.0021.00
##FFFFFF13.671.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002E74
Deuteranopia (green-blind)
#002D6F
Tritanopia (blue-blind)
#322D42
Achromatopsia (no color)
#2E2E2E

Design tokens & code

CSS
--color: #3f1271;
/* rgb */ color: rgb(63, 18, 113);
/* oklch */ color: oklch(31.8% 0.148 298.8);
Tailwind
colors: {
  custom: {
    50: '#7a569b',
    500: '#3f1271',
    950: '#000000',
  },
}
SCSS
$custom: #3f1271;
$custom-light: #7a569b;
$custom-dark: #000000;
JSON
{
  "hex": "#3f1271",
  "rgb": {
    "r": 63,
    "g": 18,
    "b": 113
  },
  "hsl": {
    "h": 268.421,
    "s": 72.519,
    "l": 25.686
  },
  "oklch": {
    "l": 0.31799,
    "c": 0.14817,
    "h": 298.8
  },
  "luminance": 0.02682
}

Semantic roles & 50–950 ramp

primary
#3F1271
secondary
#72A837
accent
#EF3999
background
#F7F5F9
surface
#EEE9F2
border
#C9C5CC
text
#0A030E
muted
#7C787E

Preview Lab

Preview with #3F1271

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

Preview Lab → · Contrast checker → · Palette generator →

#3F1271 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva