#334EA5#334EA5

#334EA5 is a mid, vivid blue. Relative luminance 0.089; OKLCH L 45.3% C 0.144 H 267.4°. Best body text is #FFFFFF at 7.57:1 contrast (WCAG AA passes).

Color values

HEX#334EA5
RGBrgb(51, 78, 165)
HSLhsl(226, 53%, 42%)
HSVhsv(226, 69%, 65%)
CMYKcmyk(69.1%, 52.7%, 0%, 35.3%)
CIE-LABlab(35.73, 19.79, -50.03)
CIE-LCHlch(35.73, 53.81, 291.58°)
OKLaboklab(45.32% -0.0065 -0.1437)
OKLCHoklch(45.32% 0.144 267.4)
XYZxyz(10.8788, 8.8681, 36.7284)
Luminance0.0887 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#334EA5 #A58A33
analogous
#3387A5 #334EA5 #5133A5
triadic
#334EA5 #A5334E #4EA533
tetradic
#334EA5 #A53387 #A58A33 #33A551
square
#334EA5 #A53387 #A58A33 #33A551
split-complementary
#334EA5 #A55133 #87A533
monochromatic
#162248 #253876 #334EA5 #4D6AC8 #7C91D6

Accessibility & contrast

On white

7.57
#334EA5 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

2.77
#334EA5 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #334EA5
7.57:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##334EA5#FFFFFF#000000##FFFFFF
##334EA51.007.572.777.57
#FFFFFF7.571.0021.001.00
#0000002.7721.001.0021.00
##FFFFFF7.571.0021.001.00

Color blindness preview

Protanopia (red-blind)
#1659A8
Deuteranopia (green-blind)
#004FA3
Tritanopia (blue-blind)
#006372
Achromatopsia (no color)
#545454

Design tokens & code

CSS
--color: #334ea5;
/* rgb */ color: rgb(51, 78, 165);
/* oklch */ color: oklch(45.3% 0.144 267.4);
Tailwind
colors: {
  custom: {
    50: '#787fc0',
    500: '#334ea5',
    950: '#000000',
  },
}
SCSS
$custom: #334ea5;
$custom-light: #787fc0;
$custom-dark: #000000;
JSON
{
  "hex": "#334ea5",
  "rgb": {
    "r": 51,
    "g": 78,
    "b": 165
  },
  "hsl": {
    "h": 225.789,
    "s": 52.778,
    "l": 42.353
  },
  "oklch": {
    "l": 0.45318,
    "c": 0.1439,
    "h": 267.4
  },
  "luminance": 0.08869
}

Semantic roles & 50–950 ramp

primary
#334EA5
secondary
#BFAE75
accent
#BA4CDC
background
#F7F7FB
surface
#EEEEF7
border
#C9C9D0
text
#0A0A12
muted
#7C7C81

Preview Lab

Preview with #334EA5

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

Preview Lab → · Contrast checker → · Palette generator →

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