#2A1254#2A1254

#2A1254 is a dark, moderate violet. Relative luminance 0.016; OKLCH L 26.3% C 0.112 H 293.9°. Best body text is #FFFFFF at 15.99:1 contrast (WCAG AA passes).

Color values

HEX#2A1254
RGBrgb(42, 18, 84)
HSLhsl(262, 65%, 20%)
HSVhsv(262, 79%, 33%)
CMYKcmyk(50%, 78.6%, 0%, 67.1%)
CIE-LABlab(13.01, 28.82, -35.59)
CIE-LCHlch(13.01, 45.80, 309.00°)
OKLaboklab(26.3% 0.0452 -0.102)
OKLCHoklch(26.3% 0.112 293.9)
XYZxyz(2.7709, 1.5649, 8.5418)
Luminance0.0157 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2A1254 #3C5412
analogous
#121B54 #2A1254 #4B1254
triadic
#2A1254 #542A12 #12542A
tetradic
#2A1254 #54121B #3C5412 #12544B
square
#2A1254 #54121B #3C5412 #12544B
split-complementary
#2A1254 #544B12 #1B5412
monochromatic
#0D0519 #110722 #2A1254 #431D86 #5C28B9

Accessibility & contrast

On white

15.99
#2A1254 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.31
#2A1254 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2A1254
15.99:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2A1254#FFFFFF#000000##FFFFFF
##2A12541.0015.991.3115.99
#FFFFFF15.991.0021.001.00
#0000001.3121.001.0021.00
##FFFFFF15.991.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002256
Deuteranopia (green-blind)
#002053
Tritanopia (blue-blind)
#1E2331
Achromatopsia (no color)
#222222

Design tokens & code

CSS
--color: #2a1254;
/* rgb */ color: rgb(42, 18, 84);
/* oklch */ color: oklch(26.3% 0.112 293.9);
Tailwind
colors: {
  custom: {
    50: '#695285',
    500: '#2a1254',
    950: '#000000',
  },
}
SCSS
$custom: #2a1254;
$custom-light: #695285;
$custom-dark: #000000;
JSON
{
  "hex": "#2a1254",
  "rgb": {
    "r": 42,
    "g": 18,
    "b": 84
  },
  "hsl": {
    "h": 261.818,
    "s": 64.706,
    "l": 20
  },
  "oklch": {
    "l": 0.26296,
    "c": 0.11156,
    "h": 293.9
  },
  "luminance": 0.01565
}

Semantic roles & 50–950 ramp

primary
#2A1254
secondary
#6D8D35
accent
#E840AB
background
#F6F4F8
surface
#EBE7EF
border
#C6C3CA
text
#07020B
muted
#7A787C

Preview Lab

Preview with #2A1254

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

Preview Lab → · Contrast checker → · Palette generator →

#2A1254 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva