#28126C#28126C

#28126C is a dark, vivid violet. Relative luminance 0.020; OKLCH L 28.6% C 0.142 H 284.1°. Best body text is #FFFFFF at 15.07:1 contrast (WCAG AA passes).

Color values

HEX#28126C
RGBrgb(40, 18, 108)
HSLhsl(255, 71%, 25%)
HSVhsv(255, 83%, 42%)
CMYKcmyk(63%, 83.3%, 0%, 57.6%)
CIE-LABlab(15.31, 35.98, -47.83)
CIE-LCHlch(15.31, 59.85, 306.95°)
OKLaboklab(28.62% 0.0346 -0.1379)
OKLCHoklch(28.62% 0.142 284.1)
XYZxyz(3.7973, 1.9662, 14.3639)
Luminance0.0197 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#28126C #566C12
analogous
#12296C #28126C #55126C
triadic
#28126C #6C2812 #126C28
tetradic
#28126C #6C1229 #566C12 #126C55
square
#28126C #6C1229 #566C12 #126C55
split-complementary
#28126C #6C5512 #296C12
monochromatic
#0A041A #150938 #28126C #3B1BA0 #4F23D5

Accessibility & contrast

On white

15.07
#28126C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.39
#28126C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #28126C
15.07:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##28126C#FFFFFF#000000##FFFFFF
##28126C1.0015.071.3915.07
#FFFFFF15.071.0021.001.00
#0000001.3921.001.0021.00
##FFFFFF15.071.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00296E
Deuteranopia (green-blind)
#00236A
Tritanopia (blue-blind)
#002D3F
Achromatopsia (no color)
#262626

Design tokens & code

CSS
--color: #28126c;
/* rgb */ color: rgb(40, 18, 108);
/* oklch */ color: oklch(28.6% 0.142 284.1);
Tailwind
colors: {
  custom: {
    50: '#6c5397',
    500: '#28126c',
    950: '#000000',
  },
}
SCSS
$custom: #28126c;
$custom-light: #6c5397;
$custom-dark: #000000;
JSON
{
  "hex": "#28126c",
  "rgb": {
    "r": 40,
    "g": 18,
    "b": 108
  },
  "hsl": {
    "h": 254.667,
    "s": 71.429,
    "l": 24.706
  },
  "oklch": {
    "l": 0.28615,
    "c": 0.14215,
    "h": 284.1
  },
  "luminance": 0.01966
}

Semantic roles & 50–950 ramp

primary
#28126C
secondary
#89A336
accent
#EE3AC2
background
#F6F4F9
surface
#ECE7F2
border
#C7C3CC
text
#08030E
muted
#7A787E

Preview Lab

Preview with #28126C

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

Preview Lab → · Contrast checker → · Palette generator →

#28126C Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva