#2F167C#2F167C

#2F167C is a dark, vivid violet. Relative luminance 0.026; OKLCH L 31.5% C 0.157 H 284.1°. Best body text is #FFFFFF at 13.76:1 contrast (WCAG AA passes).

Color values

HEX#2F167C
RGBrgb(47, 22, 124)
HSLhsl(255, 70%, 29%)
HSVhsv(255, 82%, 49%)
CMYKcmyk(62.1%, 82.3%, 0%, 51.4%)
CIE-LABlab(18.51, 39.79, -52.86)
CIE-LCHlch(18.51, 66.16, 306.97°)
OKLaboklab(31.55% 0.0382 -0.1524)
OKLCHoklch(31.55% 0.157 284.1)
XYZxyz(5.0962, 2.6331, 19.3046)
Luminance0.0263 (WCAG relative)
Temperaturecool
Familyviolet

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#2F167C #637C16
analogous
#16307C #2F167C #62167C
triadic
#2F167C #7C2F16 #167C2F
tetradic
#2F167C #7C1630 #637C16 #167C62
square
#2F167C #7C1630 #637C16 #167C62
split-complementary
#2F167C #7C6216 #307C16
monochromatic
#0A051A #1B0D48 #2F167C #431FB0 #5B32DB

Accessibility & contrast

On white

13.76
#2F167C on #FFFFFF
AA ✓AA large ✓AAA ✓

On black

1.53
#2F167C on #000000
AA ✗AA large ✗AAA ✗

Best text color

#FFFFFF on #2F167C
13.76:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##2F167C#FFFFFF#000000##FFFFFF
##2F167C1.0013.761.5313.76
#FFFFFF13.761.0021.001.00
#0000001.5321.001.0021.00
##FFFFFF13.761.0021.001.00

Color blindness preview

Protanopia (red-blind)
#00307F
Deuteranopia (green-blind)
#002A7A
Tritanopia (blue-blind)
#003549
Achromatopsia (no color)
#2D2D2D

Design tokens & code

CSS
--color: #2f167c;
/* rgb */ color: rgb(47, 22, 124);
/* oklch */ color: oklch(31.5% 0.157 284.1);
Tailwind
colors: {
  custom: {
    50: '#7257a3',
    500: '#2f167c',
    950: '#000000',
  },
}
SCSS
$custom: #2f167c;
$custom-light: #7257a3;
$custom-dark: #000000;
JSON
{
  "hex": "#2f167c",
  "rgb": {
    "r": 47,
    "g": 22,
    "b": 124
  },
  "hsl": {
    "h": 254.706,
    "s": 69.863,
    "l": 28.627
  },
  "oklch": {
    "l": 0.31548,
    "c": 0.15707,
    "h": 284.1
  },
  "luminance": 0.02633
}

Semantic roles & 50–950 ramp

primary
#2F167C
secondary
#95B13D
accent
#ED3BC1
background
#F7F5FA
surface
#EDE9F4
border
#C8C5CE
text
#09030F
muted
#7B787F

Preview Lab

Preview with #2F167C

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

Preview Lab → · Contrast checker → · Palette generator →

#2F167C Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva