Skip to content
Related Articles
Open in App
Not now

Related Articles

How to delete text from document using HTML ?

Improve Article
Save Article
  • Last Updated : 11 Jun, 2020
Improve Article
Save Article

In this article, we delete text from an HTML document by using the <del> tag in the document. This tag stands for delete and is used to mark a portion of text which has been deleted from the document.


<del> Contents... </del>

Example: In the following example, deletion of a text from a document is demonstrated.

<!DOCTYPE html>
        How to delete text from a 
        document using HTML?
        del {
            color: red;
        ins {
            color: green;
        h1 {
            color: green;
        body {
            text-align: center;
        HTML5 | How to delete 
        text from a document 
        GeeksforGeeks is a 
        science portal


Supported Browsers:

  • Google Chrome
  • Internet Explorer
  • Firefox
  • Opera
  • Safari

My Personal Notes arrow_drop_up
Related Articles

Start Your Coding Journey Now!