Home / Colors / Green hex code

Green hex code

The standard CSS green.

#008000 Green
HEX#008000
RGBrgb(0, 128, 0)
HSLhsl(120, 100%, 25%)
HSVhsv(120, 100%, 50%)
CMYKcmyk(100%, 0%, 100%, 50%)
Advertisement

About green

The standard CSS green. Pure screen green (#00FF00) is called lime in CSS. Its hex code is #008000, which is rgb(0, 128, 0): 0 red, 128 green and 0 blue on a scale of 0 to 255.

Other values you'll see for green: #00FF00 (pure screen green).

Green sits between warm and cool, so it can lean either way depending on what it's paired with.

Green tints and shades

Lighter tints (mixed with white) and darker shades (mixed with black) of green. Click any of them to copy its hex code.

Colors that go with green

Complementary

The opposite color on the color wheel, for strong contrast.

Analogous

Neighbors on the color wheel, for a calm, matching look.

Triadic

Three colors evenly spaced around the wheel, for a balanced, lively palette.

Split complementary

The two colors either side of the complement: contrast without clashing.

Text on green

White text

5.13:1 · Passes AA for all text

Black text

4.08:1 · Large text only (AA)

For readable text, WCAG asks for a contrast ratio of at least 4.5:1 (3:1 for large text). White text is the better choice on green. Test other combinations with the contrast checker.

Using green in CSS

.element {
  color: #008000;
  background-color: rgb(0 128 0);
  border-color: hsl(120 100% 25%);
}
Advertisement

Frequently asked questions

What is the hex code for green?

Green is #008000. In RGB it's rgb(0, 128, 0), and in HSL it's hsl(120, 100%, 25%).

What colors go with green?

Its complementary color is #800080, which gives strong contrast. For a softer look, use analogous colors #408000 and #008040. Green also pairs well with white.

Is green warm or cool?

Green sits between warm and cool, so it can lean either way depending on what it's paired with.

Should I use white or black text on green?

Use white text. Its contrast ratio on green is 5.13:1, versus 4.08:1 for black.

Similar colors

See all popular colors · All HTML color names · Open green in the color picker

Advertisement