#312795#312795

#312795 is a dark, vivid blue. Relative luminance 0.043; OKLCH L 36.6% C 0.171 H 277.9°. Best body text is #FFFFFF at 11.32:1 contrast (WCAG AA passes).

Color values

HEX#312795
RGBrgb(49, 39, 149)
HSLhsl(245, 59%, 37%)
HSVhsv(245, 74%, 58%)
CMYKcmyk(67.1%, 73.8%, 0%, 41.6%)
CIE-LABlab(24.56, 38.84, -58.55)
CIE-LCHlch(24.56, 70.26, 303.56°)
OKLaboklab(36.64% 0.0234 -0.1691)
OKLCHoklch(36.64% 0.171 277.9)
XYZxyz(7.4152, 4.2733, 28.8620)
Luminance0.0427 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#312795 #8B9527
analogous
#275495 #312795 #682795
triadic
#312795 #953127 #279531
tetradic
#312795 #952754 #8B9527 #279568
square
#312795 #952754 #8B9527 #279568
split-complementary
#312795 #956827 #549527
monochromatic
#110E34 #211A64 #312795 #4134C6 #6B61D6

Accessibility & contrast

On white

11.32
#312795 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.85
#312795 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #312795
11.32:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##312795#FFFFFF#000000##FFFFFF
##3127951.0011.321.8511.32
#FFFFFF11.321.0021.001.00
#0000001.8521.001.0021.00
##FFFFFF11.321.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003F98
Deuteranopia (green-blind)
#003693
Tritanopia (blue-blind)
#00465B
Achromatopsia (no color)
#3A3A3A

Design tokens & code

CSS
--color: #312795;
/* rgb */ color: rgb(49, 39, 149);
/* oklch */ color: oklch(36.6% 0.171 277.9);
Tailwind
colors: {
  custom: {
    50: '#7763b5',
    500: '#312795',
    950: '#000000',
  },
}
SCSS
$custom: #312795;
$custom-light: #7763b5;
$custom-dark: #000000;
JSON
{
  "hex": "#312795",
  "rgb": {
    "r": 49,
    "g": 39,
    "b": 149
  },
  "hsl": {
    "h": 245.455,
    "s": 58.511,
    "l": 36.863
  },
  "oklch": {
    "l": 0.36635,
    "c": 0.17069,
    "h": 277.9
  },
  "luminance": 0.04274
}

Semantic roles & 50–950 ramp

primary
#312795
secondary
#B2BB5D
accent
#E246D4
background
#F7F5FB
surface
#EEEAF6
border
#C9C6D0
text
#0A0511
muted
#7C7980

Preview Lab

Preview with #312795

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

Preview Lab → · Contrast checker → · Palette generator →

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