CSS text-decoration Property


The text-decoration CSS property specifies the decorations to be applied on the text content of an element such as underline, overline, etc

The text-decoration property specifies the decoration added to text, and is a shorthand property for:

  • text-decoration-line (required)
  • text-decoration-color
  • text-decoration-style

CSS Syntax

text-decoration: text-decoration-line text-decoration-color text-decoration-style|initial|inherit;

Possible Values

  • none − No decoration should be added to the inline text.

  • underline − An underline is drawn beneath the inline text.

  • overline − An overline is drawn above the inline text.

  • line-through − A line should be drawn through the middle of the inline text.

  • blink − The inline text should blink on and off, analogous to the BLINK element introduced by Netscape.

Example -