#40771B#40771B

#40771B is a mid, vivid yellow-green. Relative luminance 0.144; OKLCH L 51.2% C 0.135 H 135.7°. Best body text is #FFFFFF at 5.42:1 contrast (WCAG AA passes).

Color values

HEX#40771B
RGBrgb(64, 119, 27)
HSLhsl(96, 63%, 29%)
HSVhsv(96, 77%, 47%)
CMYKcmyk(46.2%, 0%, 77.3%, 53.3%)
CIE-LABlab(44.75, -34.72, 42.13)
CIE-LCHlch(44.75, 54.60, 129.49°)
OKLaboklab(51.21% -0.0968 0.0945)
OKLCHoklch(51.21% 0.135 135.7)
XYZxyz(8.9088, 14.3622, 3.3395)
Luminance0.1436 (WCAG relative)
Temperaturewarm
Familyyellow-green

Closest named colors

Perceptual scales

Shades

Tints

Tones

OKLCH scale

Color harmonies

complementary
#40771B #521B77
analogous
#6E771B #40771B #1B7724
triadic
#40771B #1B4077 #771B40
tetradic
#40771B #1B6E77 #521B77 #77241B
square
#40771B #1B6E77 #521B77 #77241B
split-complementary
#40771B #241B77 #771B6E
monochromatic
#0D1906 #254510 #40771B #5BA926 #77D23A

Accessibility & contrast

On white

5.42
#40771B on #FFFFFF
AA ✓AA large ✓AAA ✗

On black

3.87
#40771B on #000000
AA ✗AA large ✓AAA ✗

Best text color

#FFFFFF on #40771B
5.42:1 — WCAG AA (normal text) passes

Contrast matrix

fg \ bg##40771B#FFFFFF#000000##FFFFFF
##40771B1.005.423.875.42
#FFFFFF5.421.0021.001.00
#0000003.8721.001.0021.00
##FFFFFF5.421.0021.001.00

Color blindness preview

Protanopia (red-blind)
#7B6D08
Deuteranopia (green-blind)
#746824
Tritanopia (blue-blind)
#3E7265
Achromatopsia (no color)
#6A6A6A

Design tokens & code

CSS
--color: #40771b;
/* rgb */ color: rgb(64, 119, 27);
/* oklch */ color: oklch(51.2% 0.135 135.7);
Tailwind
colors: {
  custom: {
    50: '#7a9f5e',
    500: '#40771b',
    950: '#000000',
  },
}
SCSS
$custom: #40771b;
$custom-light: #7a9f5e;
$custom-dark: #000000;
JSON
{
  "hex": "#40771b",
  "rgb": {
    "r": 64,
    "g": 119,
    "b": 27
  },
  "hsl": {
    "h": 95.87,
    "s": 63.014,
    "l": 28.627
  },
  "oklch": {
    "l": 0.5121,
    "c": 0.13526,
    "h": 135.7
  },
  "luminance": 0.14363
}

Semantic roles & 50–950 ramp

primary
#40771B
secondary
#8142AB
accent
#42E6A4
background
#F7F9F5
surface
#EEF2E9
border
#C9CCC5
text
#0A0E05
muted
#7C7E79

Preview Lab

Preview with #40771B

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

Preview Lab → · Contrast checker → · Palette generator →

#40771B Color — HEX, RGB, HSL, OKLCH & Contrast — Tintiva