#2A127D#2A127D

#2A127D is a dark, vivid violet. Relative luminance 0.024; OKLCH L 30.8% C 0.162 H 281.3°. Best body text is #FFFFFF at 14.18:1 contrast (WCAG AA passes).

Color values

HEX#2A127D
RGBrgb(42, 18, 125)
HSLhsl(253, 75%, 28%)
HSVhsv(253, 86%, 49%)
CMYKcmyk(66.4%, 85.6%, 0%, 51%)
CIE-LABlab(17.48, 41.40, -55.21)
CIE-LCHlch(17.48, 69.01, 306.87°)
OKLaboklab(30.75% 0.0319 -0.1593)
OKLCHoklch(30.75% 0.162 281.3)
XYZxyz(4.8717, 2.4051, 19.6056)
Luminance0.0241 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2A127D #657D12
analogous
#122F7D #2A127D #5F127D
triadic
#2A127D #7D2A12 #127D2A
tetradic
#2A127D #7D122F #657D12 #127D5F
square
#2A127D #7D122F #657D12 #127D5F
split-complementary
#2A127D #7D5F12 #2F7D12
monochromatic
#09041B #180A48 #2A127D #3C1AB2 #5229E0

Accessibility & contrast

On white

14.18
#2A127D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.48
#2A127D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2A127D
14.18:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2A127D#FFFFFF#000000##FFFFFF
##2A127D1.0014.181.4814.18
#FFFFFF14.181.0021.001.00
#0000001.4821.001.0021.00
##FFFFFF14.181.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002E80
Deuteranopia (green-blind)
#00277B
Tritanopia (blue-blind)
#003449
Achromatopsia (no color)
#2B2B2B

Design tokens & code

CSS
--color: #2a127d;
/* rgb */ color: rgb(42, 18, 125);
/* oklch */ color: oklch(30.8% 0.162 281.3);
Tailwind
colors: {
  custom: {
    50: '#7155a4',
    500: '#2a127d',
    950: '#000000',
  },
}
SCSS
$custom: #2a127d;
$custom-light: #7155a4;
$custom-dark: #000000;
JSON
{
  "hex": "#2a127d",
  "rgb": {
    "r": 42,
    "g": 18,
    "b": 125
  },
  "hsl": {
    "h": 253.458,
    "s": 74.825,
    "l": 28.039
  },
  "oklch": {
    "l": 0.3075,
    "c": 0.16247,
    "h": 281.3
  },
  "luminance": 0.02406
}

Semantic roles & 50–950 ramp

primary
#2A127D
secondary
#97B338
accent
#F136C7
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#09030F
muted
#7B787F

Preview Lab

Preview with #2A127D

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

Preview Lab → · Contrast checker → · Palette generator →

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