brightness()

Anonymous contributor's avatar
Anonymous contributor
Anonymous contributor's avatar
Anonymous contributor
Published Jul 12, 2021Updated Sep 3, 2021
Contribute to Docs

Defines the brightness or darkness of an element.

Syntax

filter: brightness(<value>);

where a required <value> can be one of the following:

  • Number value: 0, 1.4
  • Percentage value: 100%, 50%

Example 1

Give the image a brightness of 125%:

.banner-image {
filter: brightness(125%);
}

All contributors

Looking to contribute?

Learn CSS on Codecademy