#271F75#271F75

#271F75 is a dark, vivid blue. Relative luminance 0.027; OKLCH L 31.3% C 0.140 H 278.8°. Best body text is #FFFFFF at 13.64:1 contrast (WCAG AA passes).

Color values

HEX#271F75
RGBrgb(39, 31, 117)
HSLhsl(246, 58%, 29%)
HSVhsv(246, 74%, 46%)
CMYKcmyk(66.7%, 73.5%, 0%, 54.1%)
CIE-LABlab(18.78, 31.46, -47.96)
CIE-LCHlch(18.78, 57.35, 303.26°)
OKLaboklab(31.33% 0.0213 -0.1384)
OKLCHoklch(31.33% 0.14 278.8)
XYZxyz(4.5365, 2.6953, 17.1074)
Luminance0.0270 (WCAG relative)
Temperaturecool
Familyblue

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#271F75 #6D751F
analogous
#1F4275 #271F75 #521F75
triadic
#271F75 #75271F #1F7527
tetradic
#271F75 #751F42 #6D751F #1F7552
square
#271F75 #751F42 #6D751F #1F7552
split-complementary
#271F75 #75521F #42751F
monochromatic
#080618 #171245 #271F75 #372CA5 #4F42CD

Accessibility & contrast

On white

13.64
#271F75 on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.54
#271F75 on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #271F75
13.64:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##271F75#FFFFFF#000000##FFFFFF
##271F751.0013.641.5413.64
#FFFFFF13.641.0021.001.00
#0000001.5421.001.0021.00
##FFFFFF13.641.0021.001.00

Color blindness preview

Protanopia (red-blind)
#003178
Deuteranopia (green-blind)
#002A73
Tritanopia (blue-blind)
#003647
Achromatopsia (no color)
#2E2E2E

Design tokens & code

CSS
--color: #271f75;
/* rgb */ color: rgb(39, 31, 117);
/* oklch */ color: oklch(31.3% 0.140 278.8);
Tailwind
colors: {
  custom: {
    50: '#6c5c9e',
    500: '#271f75',
    950: '#000000',
  },
}
SCSS
$custom: #271f75;
$custom-light: #6c5c9e;
$custom-dark: #000000;
JSON
{
  "hex": "#271f75",
  "rgb": {
    "r": 39,
    "g": 31,
    "b": 117
  },
  "hsl": {
    "h": 245.581,
    "s": 58.108,
    "l": 29.02
  },
  "oklch": {
    "l": 0.31329,
    "c": 0.14001,
    "h": 278.8
  },
  "luminance": 0.02696
}

Semantic roles & 50–950 ramp

primary
#271F75
secondary
#A0A947
accent
#E146D3
background
#F6F5F9
surface
#ECE9F2
border
#C7C5CC
text
#08040E
muted
#7A797E

Preview Lab

Preview with #271F75

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

Preview Lab → · Contrast checker → · Palette generator →

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