#334EA2#334EA2

#334EA2 is a mid, vivid blue. Relative luminance 0.088; OKLCH L 45.1% C 0.140 H 267.2°. Best body text is #FFFFFF at 7.63:1 contrast (WCAG AA passes).

Color values

HEX#334EA2
RGBrgb(51, 78, 162)
HSLhsl(225, 52%, 42%)
HSVhsv(225, 69%, 64%)
CMYKcmyk(68.5%, 51.9%, 0%, 36.5%)
CIE-LABlab(35.52, 18.68, -48.58)
CIE-LCHlch(35.52, 52.05, 291.03°)
OKLaboklab(45.09% -0.0068 -0.1395)
OKLCHoklch(45.09% 0.14 267.2)
XYZxyz(10.6090, 8.7602, 35.3072)
Luminance0.0876 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#334EA2 #A28733
analogous
#3386A2 #334EA2 #4F33A2
triadic
#334EA2 #A2334E #4EA233
tetradic
#334EA2 #A23386 #A28733 #33A24F
square
#334EA2 #A23386 #A28733 #33A24F
split-complementary
#334EA2 #A24F33 #86A233
monochromatic
#162145 #243873 #334EA2 #4C6AC7 #7A90D5

Accessibility & contrast

On white

7.63
#334EA2 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.75
#334EA2 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #334EA2
7.63:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##334EA2#FFFFFF#000000##FFFFFF
##334EA21.007.632.757.63
#FFFFFF7.631.0021.001.00
#0000002.7521.001.0021.00
##FFFFFF7.631.0021.001.00

Color blindness preview

Protanopia (red-blind)
#1B59A5
Deuteranopia (green-blind)
#004FA0
Tritanopia (blue-blind)
#006270
Achromatopsia (no color)
#545454

Design tokens & code

CSS
--color: #334ea2;
/* rgb */ color: rgb(51, 78, 162);
/* oklch */ color: oklch(45.1% 0.140 267.2);
Tailwind
colors: {
  custom: {
    50: '#787fbe',
    500: '#334ea2',
    950: '#000000',
  },
}
SCSS
$custom: #334ea2;
$custom-light: #787fbe;
$custom-dark: #000000;
JSON
{
  "hex": "#334ea2",
  "rgb": {
    "r": 51,
    "g": 78,
    "b": 162
  },
  "hsl": {
    "h": 225.405,
    "s": 52.113,
    "l": 41.765
  },
  "oklch": {
    "l": 0.45091,
    "c": 0.13963,
    "h": 267.2
  },
  "luminance": 0.08761
}

Semantic roles & 50–950 ramp

primary
#334EA2
secondary
#BEAC73
accent
#B94CDC
background
#F7F7FB
surface
#EEEEF7
border
#C9C9D0
text
#0A0A12
muted
#7C7C81

Preview Lab

Preview with #334EA2

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

Preview Lab → · Contrast checker → · Palette generator →

#334EA2 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva