#2A1B74#2A1B74

#2A1B74 is a dark, vivid violet. Relative luminance 0.025; OKLCH L 30.9% C 0.143 H 281.8°. Best body text is #FFFFFF at 13.93:1 contrast (WCAG AA passes).

Color values

HEX#2A1B74
RGBrgb(42, 27, 116)
HSLhsl(250, 62%, 28%)
HSVhsv(250, 77%, 45%)
CMYKcmyk(63.8%, 76.7%, 0%, 54.5%)
CIE-LABlab(18.08, 33.94, -48.45)
CIE-LCHlch(18.08, 59.15, 305.02°)
OKLaboklab(30.87% 0.0291 -0.1397)
OKLCHoklch(30.87% 0.143 281.8)
XYZxyz(4.4982, 2.5367, 16.7722)
Luminance0.0254 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2A1B74 #65741B
analogous
#1B3974 #2A1B74 #561B74
triadic
#2A1B74 #742A1B #1B742A
tetradic
#2A1B74 #741B39 #65741B #1B7456
square
#2A1B74 #741B39 #65741B #1B7456
split-complementary
#2A1B74 #74561B #39741B
monochromatic
#090619 #180F42 #2A1B74 #3C27A6 #5239D1

Accessibility & contrast

On white

13.93
#2A1B74 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.51
#2A1B74 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2A1B74
13.93:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2A1B74#FFFFFF#000000##FFFFFF
##2A1B741.0013.931.5113.93
#FFFFFF13.931.0021.001.00
#0000001.5121.001.0021.00
##FFFFFF13.931.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002F77
Deuteranopia (green-blind)
#002972
Tritanopia (blue-blind)
#003446
Achromatopsia (no color)
#2C2C2C

Design tokens & code

CSS
--color: #2a1b74;
/* rgb */ color: rgb(42, 27, 116);
/* oklch */ color: oklch(30.9% 0.143 281.8);
Tailwind
colors: {
  custom: {
    50: '#6e599d',
    500: '#2a1b74',
    950: '#000000',
  },
}
SCSS
$custom: #2a1b74;
$custom-light: #6e599d;
$custom-dark: #000000;
JSON
{
  "hex": "#2a1b74",
  "rgb": {
    "r": 42,
    "g": 27,
    "b": 116
  },
  "hsl": {
    "h": 250.112,
    "s": 62.238,
    "l": 28.039
  },
  "oklch": {
    "l": 0.3087,
    "c": 0.14268,
    "h": 281.8
  },
  "luminance": 0.02537
}

Semantic roles & 50–950 ramp

primary
#2A1B74
secondary
#97A942
accent
#E542CA
background
#F7F5F9
surface
#EDE9F2
border
#C8C5CC
text
#08040E
muted
#7B797E

Preview Lab

Preview with #2A1B74

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

Preview Lab → · Contrast checker → · Palette generator →

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