HTML <rt> Tag

The <rt> tag is used to add annotations at the top and bottom of the text, inserted in the <ruby> tag. The <ruby> tag defines a ruby annotation, a pronunciation guide for relatively obscure characters in Japanese or East Asian languages.

The annotation placed in the <rp> tag contains a tip of pronunciation and translation of the basic text (hieroglyphs). Annotation is displayed in a small print above the hieroglyphs.

The <rt> tag is one of the HTML5 elements.

Syntax

The <rt> tag comes in pairs. However the closing tag isn’t required, if it comes the last. The closing tag of the <rt> element may be omitted when <rt> is immediately followed by <rt>, <rb>, <rp> or <rtc>, or when there isn’t any content in the parent element.

Example of the HTML <rt> tag:

<!DOCTYPE html>
<html>
  <head>
    <title>Title of the document</title>
  </head>
  <body>
    <ruby><rt>Kan</rt><rt>ji</rt>
    </ruby>
  </body>
</html>

Result

Attributes

The <rt> tag supports the Global Attributes and the Event Attributes.


Browser support

5+ 38+ 5+ 15+


Do you find this helpful?

Related articles