#301796#301796

#301796 is a dark, vivid violet. Relative luminance 0.034; OKLCH L 34.7% C 0.187 H 279.4°. Best body text is #FFFFFF at 12.44:1 contrast (WCAG AA passes).

Color values

HEX#301796
RGBrgb(48, 23, 150)
HSLhsl(252, 73%, 34%)
HSVhsv(252, 85%, 59%)
CMYKcmyk(68%, 84.7%, 0%, 41.2%)
CIE-LABlab(21.74, 47.21, -63.83)
CIE-LCHlch(21.74, 79.39, 306.49°)
OKLaboklab(34.67% 0.0304 -0.1843)
OKLCHoklch(34.67% 0.187 279.4)
XYZxyz(7.0286, 3.4426, 29.1423)
Luminance0.0344 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#301796 #7D9617
analogous
#173E96 #301796 #701796
triadic
#301796 #963017 #179630
tetradic
#301796 #96173E #7D9617 #179670
square
#301796 #96173E #7D9617 #179670
split-complementary
#301796 #967017 #3E9617
monochromatic
#0E072C #1F0F61 #301796 #411FCB #6445E2

Accessibility & contrast

On white

12.44
#301796 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.69
#301796 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #301796
12.44:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##301796#FFFFFF#000000##FFFFFF
##3017961.0012.441.6912.44
#FFFFFF12.441.0021.001.00
#0000001.6921.001.0021.00
##FFFFFF12.441.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003999
Deuteranopia (green-blind)
#002F94
Tritanopia (blue-blind)
#004059
Achromatopsia (no color)
#343434

Design tokens & code

CSS
--color: #301796;
/* rgb */ color: rgb(48, 23, 150);
/* oklch */ color: oklch(34.7% 0.187 279.4);
Tailwind
colors: {
  custom: {
    50: '#785ab6',
    500: '#301796',
    950: '#000000',
  },
}
SCSS
$custom: #301796;
$custom-light: #785ab6;
$custom-dark: #000000;
JSON
{
  "hex": "#301796",
  "rgb": {
    "r": 48,
    "g": 23,
    "b": 150
  },
  "hsl": {
    "h": 251.811,
    "s": 73.41,
    "l": 33.922
  },
  "oklch": {
    "l": 0.34674,
    "c": 0.18678,
    "h": 279.4
  },
  "luminance": 0.03443
}

Semantic roles & 50–950 ramp

primary
#301796
secondary
#ABC345
accent
#F038CC
background
#F8F5FB
surface
#EFE9F6
border
#CAC5D0
text
#0A0411
muted
#7C7980

Preview Lab

Preview with #301796

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

Preview Lab → · Contrast checker → · Palette generator →

#301796 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva