#2D168D#2D168D

#2D168D is a dark, vivid violet. Relative luminance 0.031; OKLCH L 33.3% C 0.178 H 279.5°. Best body text is #FFFFFF at 13.04:1 contrast (WCAG AA passes).

Color values

HEX#2D168D
RGBrgb(45, 22, 141)
HSLhsl(252, 73%, 32%)
HSVhsv(252, 84%, 55%)
CMYKcmyk(68.1%, 84.4%, 0%, 44.7%)
CIE-LABlab(20.26, 44.71, -60.69)
CIE-LCHlch(20.26, 75.39, 306.38°)
OKLaboklab(33.28% 0.0293 -0.1752)
OKLCHoklch(33.28% 0.178 279.5)
XYZxyz(6.1753, 3.0543, 25.4582)
Luminance0.0306 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2D168D #768D16
analogous
#163A8D #2D168D #69168D
triadic
#2D168D #8D2D16 #168D2D
tetradic
#2D168D #8D163A #768D16 #168D69
square
#2D168D #8D163A #768D16 #168D69
split-complementary
#2D168D #8D6916 #3A8D16
monochromatic
#0B0523 #1C0E58 #2D168D #3E1EC2 #5C3DE1

Accessibility & contrast

On white

13.04
#2D168D on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.61
#2D168D on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2D168D
13.04:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2D168D#FFFFFF#000000##FFFFFF
##2D168D1.0013.041.6113.04
#FFFFFF13.041.0021.001.00
#0000001.6121.001.0021.00
##FFFFFF13.041.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003590
Deuteranopia (green-blind)
#002C8B
Tritanopia (blue-blind)
#003C53
Achromatopsia (no color)
#313131

Design tokens & code

CSS
--color: #2d168d;
/* rgb */ color: rgb(45, 22, 141);
/* oklch */ color: oklch(33.3% 0.178 279.5);
Tailwind
colors: {
  custom: {
    50: '#7558b0',
    500: '#2d168d',
    950: '#000000',
  },
}
SCSS
$custom: #2d168d;
$custom-light: #7558b0;
$custom-dark: #000000;
JSON
{
  "hex": "#2d168d",
  "rgb": {
    "r": 45,
    "g": 22,
    "b": 141
  },
  "hsl": {
    "h": 251.597,
    "s": 73.006,
    "l": 31.961
  },
  "oklch": {
    "l": 0.33283,
    "c": 0.17766,
    "h": 279.5
  },
  "luminance": 0.03055
}

Semantic roles & 50–950 ramp

primary
#2D168D
secondary
#A7C13E
accent
#F038CC
background
#F7F5FB
surface
#EEE9F6
border
#C9C5D0
text
#0A0411
muted
#7C7980

Preview Lab

Preview with #2D168D

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

Preview Lab → · Contrast checker → · Palette generator →

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