#2D177A#2D177A

#2D177A is a dark, vivid violet. Relative luminance 0.026; OKLCH L 31.3% C 0.154 H 283.1°. Best body text is #FFFFFF at 13.86:1 contrast (WCAG AA passes).

Color values

HEX#2D177A
RGBrgb(45, 23, 122)
HSLhsl(253, 68%, 28%)
HSVhsv(253, 81%, 48%)
CMYKcmyk(63.1%, 81.1%, 0%, 52.2%)
CIE-LABlab(18.26, 38.44, -52.00)
CIE-LCHlch(18.26, 64.67, 306.47°)
OKLaboklab(31.26% 0.0349 -0.1499)
OKLCHoklch(31.26% 0.154 283.1)
XYZxyz(4.9003, 2.5755, 18.6475)
Luminance0.0258 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2D177A #647A17
analogous
#17327A #2D177A #5E177A
triadic
#2D177A #7A2D17 #177A2D
tetradic
#2D177A #7A1732 #647A17 #177A5E
square
#2D177A #7A1732 #647A17 #177A5E
split-complementary
#2D177A #7A5E17 #327A17
monochromatic
#09051A #1A0D47 #2D177A #4021AD #5833D9

Accessibility & contrast

On white

13.86
#2D177A on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.52
#2D177A on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2D177A
13.86:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2D177A#FFFFFF#000000##FFFFFF
##2D177A1.0013.861.5213.86
#FFFFFF13.861.0021.001.00
#0000001.5221.001.0021.00
##FFFFFF13.861.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00307D
Deuteranopia (green-blind)
#002978
Tritanopia (blue-blind)
#003448
Achromatopsia (no color)
#2D2D2D

Design tokens & code

CSS
--color: #2d177a;
/* rgb */ color: rgb(45, 23, 122);
/* oklch */ color: oklch(31.3% 0.154 283.1);
Tailwind
colors: {
  custom: {
    50: '#7158a2',
    500: '#2d177a',
    950: '#000000',
  },
}
SCSS
$custom: #2d177a;
$custom-light: #7158a2;
$custom-dark: #000000;
JSON
{
  "hex": "#2d177a",
  "rgb": {
    "r": 45,
    "g": 23,
    "b": 122
  },
  "hsl": {
    "h": 253.333,
    "s": 68.276,
    "l": 28.431
  },
  "oklch": {
    "l": 0.31256,
    "c": 0.15396,
    "h": 283.1
  },
  "luminance": 0.02576
}

Semantic roles & 50–950 ramp

primary
#2D177A
secondary
#96AF3E
accent
#EB3DC4
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#09030F
muted
#7B787F

Preview Lab

Preview with #2D177A

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

Preview Lab → · Contrast checker → · Palette generator →

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