#31398A#31398A

#31398A is a dark, vivid blue. Relative luminance 0.054; OKLCH L 38.8% C 0.133 H 274.1°. Best body text is #FFFFFF at 10.08:1 contrast (WCAG AA passes).

Color values

HEX#31398A
RGBrgb(49, 57, 138)
HSLhsl(235, 48%, 37%)
HSVhsv(235, 64%, 54%)
CMYKcmyk(64.5%, 58.7%, 0%, 45.9%)
CIE-LABlab(27.88, 23.54, -46.32)
CIE-LCHlch(27.88, 51.96, 296.94°)
OKLaboklab(38.76% 0.0096 -0.1331)
OKLCHoklch(38.76% 0.133 274.1)
XYZxyz(7.3157, 5.4136, 24.6992)
Luminance0.0541 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#31398A #8A8231
analogous
#31668A #31398A #56318A
triadic
#31398A #8A3139 #398A31
tetradic
#31398A #8A3166 #8A8231 #318A56
square
#31398A #8A3166 #8A8231 #318A56
split-complementary
#31398A #8A5631 #668A31
monochromatic
#111430 #21265D #31398A #414CB7 #6B74CA

Accessibility & contrast

On white

10.08
#31398A on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.08
#31398A on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #31398A
10.08:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##31398A#FFFFFF#000000##FFFFFF
##31398A1.0010.082.0810.08
#FFFFFF10.081.0021.001.00
#0000002.0821.001.0021.00
##FFFFFF10.081.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00468D
Deuteranopia (green-blind)
#003E88
Tritanopia (blue-blind)
#004C5B
Achromatopsia (no color)
#424242

Design tokens & code

CSS
--color: #31398a;
/* rgb */ color: rgb(49, 57, 138);
/* oklch */ color: oklch(38.8% 0.133 274.1);
Tailwind
colors: {
  custom: {
    50: '#736fad',
    500: '#31398a',
    950: '#000000',
  },
}
SCSS
$custom: #31398a;
$custom-light: #736fad;
$custom-dark: #000000;
JSON
{
  "hex": "#31398a",
  "rgb": {
    "r": 49,
    "g": 57,
    "b": 138
  },
  "hsl": {
    "h": 234.607,
    "s": 47.594,
    "l": 36.667
  },
  "oklch": {
    "l": 0.38756,
    "c": 0.13348,
    "h": 274.1
  },
  "luminance": 0.05414
}

Semantic roles & 50–950 ramp

primary
#31398A
secondary
#B2AB65
accent
#CB51D7
background
#F7F6FA
surface
#EDECF4
border
#C8C7CE
text
#090710
muted
#7B7A7F

Preview Lab

Preview with #31398A

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

Preview Lab → · Contrast checker → · Palette generator →

#31398A Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva