#2A1170#2A1170

#2A1170 is a dark, vivid violet. Relative luminance 0.021; OKLCH L 29.2% C 0.148 H 284.6°. Best body text is #FFFFFF at 14.87:1 contrast (WCAG AA passes).

Color values

HEX#2A1170
RGBrgb(42, 17, 112)
HSLhsl(256, 74%, 25%)
HSVhsv(256, 85%, 44%)
CMYKcmyk(62.5%, 84.8%, 0%, 56.1%)
CIE-LABlab(15.81, 37.93, -49.60)
CIE-LCHlch(15.81, 62.44, 307.41°)
OKLaboklab(29.15% 0.0372 -0.143)
OKLCHoklch(29.15% 0.148 284.6)
XYZxyz(4.0790, 2.0627, 15.5093)
Luminance0.0206 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2A1170 #577011
analogous
#112870 #2A1170 #591170
triadic
#2A1170 #702A11 #11702A
tetradic
#2A1170 #701128 #577011 #117059
square
#2A1170 #701128 #577011 #117059
split-complementary
#2A1170 #705911 #287011
monochromatic
#0A041B #16093B #2A1170 #3E19A5 #5221DA

Accessibility & contrast

On white

14.87
#2A1170 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.41
#2A1170 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2A1170
14.87:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2A1170#FFFFFF#000000##FFFFFF
##2A11701.0014.871.4114.87
#FFFFFF14.871.0021.001.00
#0000001.4121.001.0021.00
##FFFFFF14.871.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002A73
Deuteranopia (green-blind)
#00246E
Tritanopia (blue-blind)
#002E41
Achromatopsia (no color)
#272727

Design tokens & code

CSS
--color: #2a1170;
/* rgb */ color: rgb(42, 17, 112);
/* oklch */ color: oklch(29.2% 0.148 284.6);
Tailwind
colors: {
  custom: {
    50: '#6e539a',
    500: '#2a1170',
    950: '#000000',
  },
}
SCSS
$custom: #2a1170;
$custom-light: #6e539a;
$custom-dark: #000000;
JSON
{
  "hex": "#2a1170",
  "rgb": {
    "r": 42,
    "g": 17,
    "b": 112
  },
  "hsl": {
    "h": 255.789,
    "s": 73.643,
    "l": 25.294
  },
  "oklch": {
    "l": 0.29151,
    "c": 0.14771,
    "h": 284.6
  },
  "luminance": 0.02063
}

Semantic roles & 50–950 ramp

primary
#2A1170
secondary
#89A735
accent
#F037C0
background
#F7F4F9
surface
#EDE8F2
border
#C8C4CC
text
#08030E
muted
#7B787E

Preview Lab

Preview with #2A1170

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

Preview Lab → · Contrast checker → · Palette generator →

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