CSS opacity property

Description

CSS opacity property determines the transparency of an element. The value of opacity varies from 0 to 1 i.e. [0-1]

Syntax

opacity : value between 0 and 1

Property values

fully opaqueDefault

The object (element) is fully opaque.

opacity: 1;

fully transparent

The object (element) is fully transparent.

opacity: 0;

partially transparency

It represents 50% transparency of the object (element).

opacity: 0.5;

Applicable to

It applies to all elements

#CSS digger
Was this article helpful?

 
Observe the transparent behavior due to opacity
×

Ctrl+D