#2D128D#2D128D

#2D128D is a dark, vivid violet. Relative luminance 0.029; OKLCH L 32.9% C 0.181 H 279.9°. Best body text is #FFFFFF at 13.27:1 contrast (WCAG AA passes).

Color values

HEX#2D128D
RGBrgb(45, 18, 141)
HSLhsl(253, 77%, 31%)
HSVhsv(253, 87%, 55%)
CMYKcmyk(68.1%, 87.2%, 0%, 44.7%)
CIE-LABlab(19.69, 46.39, -61.64)
CIE-LCHlch(19.69, 77.14, 306.97°)
OKLaboklab(32.89% 0.0309 -0.1779)
OKLCHoklch(32.89% 0.181 279.9)
XYZxyz(6.1047, 2.9131, 25.4347)
Luminance0.0291 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2D128D #728D12
analogous
#12348D #2D128D #6A128D
triadic
#2D128D #8D2D12 #128D2D
tetradic
#2D128D #8D1234 #728D12 #128D6A
square
#2D128D #8D1234 #728D12 #128D6A
split-complementary
#2D128D #8D6A12 #348D12
monochromatic
#0A0420 #1C0B57 #2D128D #3E19C3 #5B34E5

Accessibility & contrast

On white

13.27
#2D128D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.58
#2D128D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2D128D
13.27:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2D128D#FFFFFF#000000##FFFFFF
##2D128D1.0013.271.5813.27
#FFFFFF13.271.0021.001.00
#0000001.5821.001.0021.00
##FFFFFF13.271.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003490
Deuteranopia (green-blind)
#002B8B
Tritanopia (blue-blind)
#003A52
Achromatopsia (no color)
#303030

Design tokens & code

CSS
--color: #2d128d;
/* rgb */ color: rgb(45, 18, 141);
/* oklch */ color: oklch(32.9% 0.181 279.9);
Tailwind
colors: {
  custom: {
    50: '#7557b0',
    500: '#2d128d',
    950: '#000000',
  },
}
SCSS
$custom: #2d128d;
$custom-light: #7557b0;
$custom-dark: #000000;
JSON
{
  "hex": "#2d128d",
  "rgb": {
    "r": 45,
    "g": 18,
    "b": 141
  },
  "hsl": {
    "h": 253.171,
    "s": 77.358,
    "l": 31.176
  },
  "oklch": {
    "l": 0.32894,
    "c": 0.18058,
    "h": 279.9
  },
  "luminance": 0.02914
}

Semantic roles & 50–950 ramp

primary
#2D128D
secondary
#A3C139
accent
#F434CA
background
#F7F5FB
surface
#EEE9F6
border
#C9C5D0
text
#0A0311
muted
#7C7880

Preview Lab

Preview with #2D128D

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

Preview Lab → · Contrast checker → · Palette generator →

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