#271F62#271F62

#271F62 is a dark, moderate blue. Relative luminance 0.023; OKLCH L 29.5% C 0.113 H 282.3°. Best body text is #FFFFFF at 14.40:1 contrast (WCAG AA passes).

Color values

HEX#271F62
RGBrgb(39, 31, 98)
HSLhsl(247, 52%, 25%)
HSVhsv(247, 68%, 38%)
CMYKcmyk(60.2%, 68.4%, 0%, 61.6%)
CIE-LABlab(16.95, 24.78, -38.56)
CIE-LCHlch(16.95, 45.84, 302.73°)
OKLaboklab(29.45% 0.0242 -0.1108)
OKLCHoklch(29.45% 0.113 282.3)
XYZxyz(3.5306, 2.2929, 11.8094)
Luminance0.0229 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#271F62 #5A621F
analogous
#1F3862 #271F62 #481F62
triadic
#271F62 #62271F #1F6227
tetradic
#271F62 #621F38 #5A621F #1F6248
square
#271F62 #621F38 #5A621F #1F6248
split-complementary
#271F62 #62481F #38621F
monochromatic
#090717 #141034 #271F62 #3A2E90 #4C3CBF

Accessibility & contrast

On white

14.40
#271F62 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.46
#271F62 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #271F62
14.40:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##271F62#FFFFFF#000000##FFFFFF
##271F621.0014.401.4614.40
#FFFFFF14.401.0021.001.00
#0000001.4621.001.0021.00
##FFFFFF14.401.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002C64
Deuteranopia (green-blind)
#002761
Tritanopia (blue-blind)
#09303D
Achromatopsia (no color)
#2A2A2A

Design tokens & code

CSS
--color: #271f62;
/* rgb */ color: rgb(39, 31, 98);
/* oklch */ color: oklch(29.5% 0.113 282.3);
Tailwind
colors: {
  custom: {
    50: '#685b8f',
    500: '#271f62',
    950: '#000000',
  },
}
SCSS
$custom: #271f62;
$custom-light: #685b8f;
$custom-dark: #000000;
JSON
{
  "hex": "#271f62",
  "rgb": {
    "r": 39,
    "g": 31,
    "b": 98
  },
  "hsl": {
    "h": 247.164,
    "s": 51.938,
    "l": 25.294
  },
  "oklch": {
    "l": 0.29452,
    "c": 0.11344,
    "h": 282.3
  },
  "luminance": 0.02293
}

Semantic roles & 50–950 ramp

primary
#271F62
secondary
#8D9746
accent
#DB4CCA
background
#F6F5F8
surface
#EBE9F0
border
#C6C5CB
text
#07040C
muted
#7A797D

Preview Lab

Preview with #271F62

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

Preview Lab → · Contrast checker → · Palette generator →

#271F62 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva