<ins>

The HTML <ins> element indicates content that has been added to a document, often shown with an underline to highlight recent modifications or updates.

ins tag

The <ins> HTML element is used to indicate text that has been inserted into a document. To show removed text, use the <del> element.

Syntax

index.html
<ins>Inserted text</ins>

ins Demo

My favorite color is blue green!

index.html
<p>My favorite color is <del>blue</del> 
<ins>green</ins>!</p>

In this example:

  • The <ins> tag highlights added text.
  • The <del> tag marks removed text.
Use the <del> tag to indicate deleted content.

Attributes

The <ins> element is commonly used for tracking edits in documents and code diffs. It supports the following attributes:

cite

Specifies the URI of a resource explaining the change, such as a meeting record or a support ticket.

datetime

Indicates when the change was made. It must be a valid date with an optional time component.

Conclusion

The <ins> tag is useful for highlighting added text, often in combination with <del> for tracking changes. The optional cite and datetime attributes provide additional details, making it a valuable tool for collaborative editing and content revisions.