Open In App

HTML del Tag

Last Updated : 11 Jul, 2025
Comments
Improve
Suggest changes
Like Article
Like
Report

The HTML <del> tag is used to indicate text that has been deleted from a document.

  • It visually represents this deletion by striking through the text, which helps in tracking changes or revisions in documents.
  • It provides semantic meaning for content that has been intentionally removed, such as in editing or version control scenarios.
HTML
<!DOCTYPE html>
<html>

<body>
  <p>
    GeeksforGeeks is a
    <del>mathematical</del>
    science portal
  </p>
</body>

</html>

Syntax

<del attr="values"> Contents... </del>

Attributes

Attributes

Description

cite

It is used to specify the URL of the document or message which denotes the reason for deleting the text.

datetime

It is used to specify the date and time of the deleted text.

<del> tag with datetime attribute

HTML
<!DOCTYPE html>
<html>

<head>
  <style>
    del {
      color: red;
      text-decoration: line-through;
    }
  </style>
</head>

<body>
  <p>
    The project deadline has been changed from
    <del datetime="2024-01-03T12:00:00Z">January 15, 2024</del>
    to January 30, 2024.
  </p>
  <p>
    The following feature was removed:
    <del datetime="2024-01-05T12:00:00Z">User authentication via email</del>.
  </p>
</body>

</html>

Similar Reads