#271F54#271F54

#271F54 is a dark, moderate blue. Relative luminance 0.021; OKLCH L 28.2% C 0.093 H 285.7°. Best body text is #FFFFFF at 14.89:1 contrast (WCAG AA passes).

Color values

HEX#271F54
RGBrgb(39, 31, 84)
HSLhsl(249, 46%, 23%)
HSVhsv(249, 63%, 33%)
CMYKcmyk(53.6%, 63.1%, 0%, 67.1%)
CIE-LABlab(15.75, 19.84, -31.15)
CIE-LCHlch(15.75, 36.93, 302.49°)
OKLaboklab(28.19% 0.0251 -0.0891)
OKLCHoklch(28.19% 0.093 285.7)
XYZxyz(2.9264, 2.0513, 8.6275)
Luminance0.0205 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#271F54 #4C541F
analogous
#1F3154 #271F54 #421F54
triadic
#271F54 #54271F #1F5427
tetradic
#271F54 #541F31 #4C541F #1F5442
square
#271F54 #541F31 #4C541F #1F5442
split-complementary
#271F54 #54421F #31541F
monochromatic
#0A0816 #120F27 #271F54 #3C2F81 #5140AD

Accessibility & contrast

On white

14.89
#271F54 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.41
#271F54 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #271F54
14.89:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##271F54#FFFFFF#000000##FFFFFF
##271F541.0014.891.4114.89
#FFFFFF14.891.0021.001.00
#0000001.4121.001.0021.00
##FFFFFF14.891.0021.001.00

Color blindness preview

Protanopia (red-blind)
#002956
Deuteranopia (green-blind)
#002653
Tritanopia (blue-blind)
#172B36
Achromatopsia (no color)
#272727

Design tokens & code

CSS
--color: #271f54;
/* rgb */ color: rgb(39, 31, 84);
/* oklch */ color: oklch(28.2% 0.093 285.7);
Tailwind
colors: {
  custom: {
    50: '#655b84',
    500: '#271f54',
    950: '#000000',
  },
}
SCSS
$custom: #271f54;
$custom-light: #655b84;
$custom-dark: #000000;
JSON
{
  "hex": "#271f54",
  "rgb": {
    "r": 39,
    "g": 31,
    "b": 84
  },
  "hsl": {
    "h": 249.057,
    "s": 46.087,
    "l": 22.549
  },
  "oklch": {
    "l": 0.28195,
    "c": 0.09252,
    "h": 285.7
  },
  "luminance": 0.02051
}

Semantic roles & 50–950 ramp

primary
#271F54
secondary
#7F8946
accent
#D652C2
background
#F6F5F8
surface
#EBE9EF
border
#C6C5CA
text
#06040B
muted
#7A797C

Preview Lab

Preview with #271F54

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

Preview Lab → · Contrast checker → · Palette generator →

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