#342A98#342A98

#342A98 is a dark, vivid blue. Relative luminance 0.047; OKLCH L 37.6% C 0.171 H 278.4°. Best body text is #FFFFFF at 10.88:1 contrast (WCAG AA passes).

Color values

HEX#342A98
RGBrgb(52, 42, 152)
HSLhsl(245, 57%, 38%)
HSVhsv(245, 72%, 60%)
CMYKcmyk(65.8%, 72.4%, 0%, 40.4%)
CIE-LABlab(25.72, 38.47, -58.47)
CIE-LCHlch(25.72, 69.99, 303.34°)
OKLaboklab(37.62% 0.0249 -0.1688)
OKLCHoklch(37.62% 0.171 278.4)
XYZxyz(7.9098, 4.6523, 30.1808)
Luminance0.0465 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#342A98 #8E982A
analogous
#2A5798 #342A98 #6B2A98
triadic
#342A98 #98342A #2A9834
tetradic
#342A98 #982A57 #8E982A #2A986B
square
#342A98 #982A57 #8E982A #2A986B
split-complementary
#342A98 #986B2A #57982A
monochromatic
#131038 #241D68 #342A98 #4437C8 #7167D5

Accessibility & contrast

On white

10.88
#342A98 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.93
#342A98 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #342A98
10.88:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##342A98#FFFFFF#000000##FFFFFF
##342A981.0010.881.9310.88
#FFFFFF10.881.0021.001.00
#0000001.9321.001.0021.00
##FFFFFF10.881.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00419B
Deuteranopia (green-blind)
#003896
Tritanopia (blue-blind)
#00485E
Achromatopsia (no color)
#3D3D3D

Design tokens & code

CSS
--color: #342a98;
/* rgb */ color: rgb(52, 42, 152);
/* oklch */ color: oklch(37.6% 0.171 278.4);
Tailwind
colors: {
  custom: {
    50: '#7965b7',
    500: '#342a98',
    950: '#000000',
  },
}
SCSS
$custom: #342a98;
$custom-light: #7965b7;
$custom-dark: #000000;
JSON
{
  "hex": "#342a98",
  "rgb": {
    "r": 52,
    "g": 42,
    "b": 152
  },
  "hsl": {
    "h": 245.455,
    "s": 56.701,
    "l": 38.039
  },
  "oklch": {
    "l": 0.37616,
    "c": 0.17059,
    "h": 278.4
  },
  "luminance": 0.04653
}

Semantic roles & 50–950 ramp

primary
#342A98
secondary
#B3BB62
accent
#E048D2
background
#F7F6FB
surface
#EEEBF6
border
#C9C6D0
text
#0A0611
muted
#7C7A80

Preview Lab

Preview with #342A98

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

Preview Lab → · Contrast checker → · Palette generator →

#342A98 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva