#2A173F#2A173F

#2A173F is a dark, moderate violet. Relative luminance 0.015; OKLCH L 25.3% C 0.075 H 303.4°. Best body text is #FFFFFF at 16.24:1 contrast (WCAG AA passes).

Color values

HEX#2A173F
RGBrgb(42, 23, 63)
HSLhsl(269, 47%, 17%)
HSVhsv(269, 63%, 25%)
CMYKcmyk(33.3%, 63.5%, 0%, 75.3%)
CIE-LABlab(12.38, 19.27, -22.07)
CIE-LCHlch(12.38, 29.30, 311.13°)
OKLaboklab(25.28% 0.0411 -0.0623)
OKLCHoklch(25.28% 0.075 303.4)
XYZxyz(2.1582, 1.4639, 4.8705)
Luminance0.0146 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2A173F #2C3F17
analogous
#17183F #2A173F #3E173F
triadic
#2A173F #3F2A17 #173F2A
tetradic
#2A173F #3F1718 #2C3F17 #173F3E
square
#2A173F #3F1718 #2C3F17 #173F3E
split-complementary
#2A173F #3F3E17 #183F17
monochromatic
#0F0816 #0F0816 #2A173F #48276C #663899

Accessibility & contrast

On white

16.24
#2A173F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.29
#2A173F on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2A173F
16.24:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2A173F#FFFFFF#000000##FFFFFF
##2A173F1.0016.241.2916.24
#FFFFFF16.241.0021.001.00
#0000001.2921.001.0021.00
##FFFFFF16.241.0021.001.00

Color blindness preview

Protanopia (red-blind)
#082040
Deuteranopia (green-blind)
#0E203E
Tritanopia (blue-blind)
#261F28
Achromatopsia (no color)
#202020

Design tokens & code

CSS
--color: #2a173f;
/* rgb */ color: rgb(42, 23, 63);
/* oklch */ color: oklch(25.3% 0.075 303.4);
Tailwind
colors: {
  custom: {
    50: '#655574',
    500: '#2a173f',
    950: '#000000',
  },
}
SCSS
$custom: #2a173f;
$custom-light: #655574;
$custom-dark: #000000;
JSON
{
  "hex": "#2a173f",
  "rgb": {
    "r": 42,
    "g": 23,
    "b": 63
  },
  "hsl": {
    "h": 268.5,
    "s": 46.512,
    "l": 16.863
  },
  "oklch": {
    "l": 0.25275,
    "c": 0.0746,
    "h": 303.4
  },
  "luminance": 0.01464
}

Semantic roles & 50–950 ramp

primary
#2A173F
secondary
#5A763C
accent
#D65297
background
#F6F4F7
surface
#EBE7ED
border
#C6C3C8
text
#060308
muted
#7A787B

Preview Lab

Preview with #2A173F

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

Preview Lab → · Contrast checker → · Palette generator →

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