#28127C#28127C

#28127C is a dark, vivid violet. Relative luminance 0.023; OKLCH L 30.5% C 0.162 H 280.3°. Best body text is #FFFFFF at 14.31:1 contrast (WCAG AA passes).

Color values

HEX#28127C
RGBrgb(40, 18, 124)
HSLhsl(252, 75%, 28%)
HSVhsv(252, 85%, 49%)
CMYKcmyk(67.7%, 85.5%, 0%, 51.4%)
CIE-LABlab(17.17, 40.91, -55.09)
CIE-LCHlch(17.17, 68.62, 306.60°)
OKLaboklab(30.45% 0.029 -0.159)
OKLCHoklch(30.45% 0.162 280.3)
XYZxyz(4.7283, 2.3386, 19.2671)
Luminance0.0234 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#28127C #667C12
analogous
#12317C #28127C #5D127C
triadic
#28127C #7C2812 #127C28
tetradic
#28127C #7C1231 #667C12 #127C5D
square
#28127C #7C1231 #667C12 #127C5D
split-complementary
#28127C #7C5D12 #317C12
monochromatic
#09041B #170A47 #28127C #391AB1 #4F29E0

Accessibility & contrast

On white

14.31
#28127C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.47
#28127C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #28127C
14.31:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##28127C#FFFFFF#000000##FFFFFF
##28127C1.0014.311.4714.31
#FFFFFF14.311.0021.001.00
#0000001.4721.001.0021.00
##FFFFFF14.311.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002E7F
Deuteranopia (green-blind)
#00267A
Tritanopia (blue-blind)
#003348
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #28127c;
/* rgb */ color: rgb(40, 18, 124);
/* oklch */ color: oklch(30.5% 0.162 280.3);
Tailwind
colors: {
  custom: {
    50: '#7055a3',
    500: '#28127c',
    950: '#000000',
  },
}
SCSS
$custom: #28127c;
$custom-light: #7055a3;
$custom-dark: #000000;
JSON
{
  "hex": "#28127c",
  "rgb": {
    "r": 40,
    "g": 18,
    "b": 124
  },
  "hsl": {
    "h": 252.453,
    "s": 74.648,
    "l": 27.843
  },
  "oklch": {
    "l": 0.30453,
    "c": 0.16164,
    "h": 280.3
  },
  "luminance": 0.02339
}

Semantic roles & 50–950 ramp

primary
#28127C
secondary
#99B238
accent
#F137CB
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#08030F
muted
#7B787F

Preview Lab

Preview with #28127C

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

Preview Lab → · Contrast checker → · Palette generator →

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