#B340D2#B340D2

#B340D2 is a mid, highly saturated purple. Relative luminance 0.179; OKLCH L 59.3% C 0.226 H 318.2°. Best body text is #000000 at 4.58:1 contrast (WCAG AA passes).

Color values

HEX#B340D2
RGBrgb(179, 64, 210)
HSLhsl(287, 62%, 54%)
HSVhsv(287, 70%, 82%)
CMYKcmyk(14.8%, 69.5%, 0%, 17.6%)
CIE-LABlab(49.38, 66.22, -53.69)
CIE-LCHlch(49.38, 85.25, 320.97°)
OKLaboklab(59.26% 0.1687 -0.1506)
OKLCHoklch(59.26% 0.226 318.2)
XYZxyz(32.0551, 17.9051, 62.7278)
Luminance0.1790 (WCAG relative)
Temperaturecool
Familypurple

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#B340D2 #5FD240
analogous
#6A40D2 #B340D2 #D240A8
triadic
#B340D2 #D2B340 #40D2B3
tetradic
#B340D2 #D26A40 #5FD240 #40A8D2
square
#B340D2 #D26A40 #5FD240 #40A8D2
split-complementary
#B340D2 #A8D240 #40D26A
monochromatic
#671D7B #9029AC #B340D2 #C772DE #DAA3E9

Accessibility & contrast

On white

4.58
#B340D2 on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

4.58
#B340D2 on #000000
AA ✓AA large ✓AAA ✗

Best text color

#000000 on #B340D2
4.58:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##B340D2#FFFFFF#000000##000000
##B340D21.004.584.584.58
#FFFFFF4.581.0021.0021.00
#0000004.5821.001.001.00
##0000004.5821.001.001.00

Color blindness preview

Protanopia (red-blind)
#006ED6
Deuteranopia (green-blind)
#4779CF
Tritanopia (blue-blind)
#B25C85
Achromatopsia (no color)
#757575

Design tokens & code

CSS
--color: #b340d2;
/* rgb */ color: rgb(179, 64, 210);
/* oklch */ color: oklch(59.3% 0.226 318.2);
Tailwind
colors: {
  custom: {
    50: '#ce7ee0',
    500: '#b340d2',
    950: '#000000',
  },
}
SCSS
$custom: #b340d2;
$custom-light: #ce7ee0;
$custom-dark: #000000;
JSON
{
  "hex": "#b340d2",
  "rgb": {
    "r": 179,
    "g": 64,
    "b": 210
  },
  "hsl": {
    "h": 287.26,
    "s": 61.864,
    "l": 53.725
  },
  "oklch": {
    "l": 0.59264,
    "c": 0.22616,
    "h": 318.2
  },
  "luminance": 0.17904
}

Semantic roles & 50–950 ramp

primary
#B340D2
secondary
#A5D698
accent
#E54365
background
#FDF8FD
surface
#FAEFFB
border
#D3CAD4
text
#140B15
muted
#837C83

Preview Lab

Preview with #B340D2

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

Preview Lab → · Contrast checker → · Palette generator →

#B340D2 Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva