#2A126F#2A126F

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

Color values

HEX#2A126F
RGBrgb(42, 18, 111)
HSLhsl(255, 72%, 25%)
HSVhsv(255, 84%, 44%)
CMYKcmyk(62.2%, 83.8%, 0%, 56.5%)
CIE-LABlab(15.86, 37.15, -48.87)
CIE-LCHlch(15.86, 61.39, 307.24°)
OKLaboklab(29.15% 0.0369 -0.1408)
OKLCHoklch(29.15% 0.146 284.7)
XYZxyz(4.0395, 2.0723, 15.2230)
Luminance0.0207 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2A126F #576F12
analogous
#12286F #2A126F #58126F
triadic
#2A126F #6F2A12 #126F2A
tetradic
#2A126F #6F1228 #576F12 #126F58
square
#2A126F #6F1228 #576F12 #126F58
split-complementary
#2A126F #6F5812 #286F12
monochromatic
#0A041A #16093A #2A126F #3E1BA4 #5223D8

Accessibility & contrast

On white

14.85
#2A126F on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

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

Best text color

#FFFFFF on #2A126F
14.85:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2A126F#FFFFFF#000000##FFFFFF
##2A126F1.0014.851.4114.85
#FFFFFF14.851.0021.001.00
#0000001.4121.001.0021.00
##FFFFFF14.851.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002A72
Deuteranopia (green-blind)
#00256D
Tritanopia (blue-blind)
#012E41
Achromatopsia (no color)
#272727

Design tokens & code

CSS
--color: #2a126f;
/* rgb */ color: rgb(42, 18, 111);
/* oklch */ color: oklch(29.2% 0.146 284.7);
Tailwind
colors: {
  custom: {
    50: '#6e5499',
    500: '#2a126f',
    950: '#000000',
  },
}
SCSS
$custom: #2a126f;
$custom-light: #6e5499;
$custom-dark: #000000;
JSON
{
  "hex": "#2a126f",
  "rgb": {
    "r": 42,
    "g": 18,
    "b": 111
  },
  "hsl": {
    "h": 255.484,
    "s": 72.093,
    "l": 25.294
  },
  "oklch": {
    "l": 0.29151,
    "c": 0.14559,
    "h": 284.7
  },
  "luminance": 0.02073
}

Semantic roles & 50–950 ramp

primary
#2A126F
secondary
#89A637
accent
#EF39C0
background
#F7F5F9
surface
#EDE8F2
border
#C8C4CC
text
#08030E
muted
#7B787E

Preview Lab

Preview with #2A126F

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

Preview Lab → · Contrast checker → · Palette generator →

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