#2A175F#2A175F

#2A175F is a dark, moderate violet. Relative luminance 0.019; OKLCH L 28.1% C 0.120 H 288.3°. Best body text is #FFFFFF at 15.15:1 contrast (WCAG AA passes).

Color values

HEX#2A175F
RGBrgb(42, 23, 95)
HSLhsl(256, 61%, 23%)
HSVhsv(256, 76%, 37%)
CMYKcmyk(55.8%, 75.8%, 0%, 62.7%)
CIE-LABlab(15.12, 29.40, -39.55)
CIE-LCHlch(15.12, 49.28, 306.63°)
OKLaboklab(28.12% 0.0375 -0.1136)
OKLCHoklch(28.12% 0.12 288.3)
XYZxyz(3.3262, 1.9311, 11.0217)
Luminance0.0193 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2A175F #4C5F17
analogous
#17285F #2A175F #4E175F
triadic
#2A175F #5F2A17 #175F2A
tetradic
#2A175F #5F1728 #4C5F17 #175F4E
square
#2A175F #5F1728 #4C5F17 #175F4E
split-complementary
#2A175F #5F4E17 #285F17
monochromatic
#0B0619 #140B2E #2A175F #402390 #562FC2

Accessibility & contrast

On white

15.15
#2A175F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.39
#2A175F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2A175F
15.15:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2A175F#FFFFFF#000000##FFFFFF
##2A175F1.0015.151.3915.15
#FFFFFF15.151.0021.001.00
#0000001.3921.001.0021.00
##FFFFFF15.151.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002761
Deuteranopia (green-blind)
#00245E
Tritanopia (blue-blind)
#162A39
Achromatopsia (no color)
#262626

Design tokens & code

CSS
--color: #2a175f;
/* rgb */ color: rgb(42, 23, 95);
/* oklch */ color: oklch(28.1% 0.120 288.3);
Tailwind
colors: {
  custom: {
    50: '#6a568d',
    500: '#2a175f',
    950: '#000000',
  },
}
SCSS
$custom: #2a175f;
$custom-light: #6a568d;
$custom-dark: #000000;
JSON
{
  "hex": "#2a175f",
  "rgb": {
    "r": 42,
    "g": 23,
    "b": 95
  },
  "hsl": {
    "h": 255.833,
    "s": 61.017,
    "l": 23.137
  },
  "oklch": {
    "l": 0.28121,
    "c": 0.11967,
    "h": 288.3
  },
  "luminance": 0.01931
}

Semantic roles & 50–950 ramp

primary
#2A175F
secondary
#7E963C
accent
#E444BA
background
#F6F5F8
surface
#EBE9F0
border
#C6C5CB
text
#07030C
muted
#7A787D

Preview Lab

Preview with #2A175F

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

Preview Lab → · Contrast checker → · Palette generator →

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