Published Aug 18, 2023Updated Sep 5, 2023
Contribute to Docs

The <ruby> tag is a semantic HTML element that represents small annotations usually used for showing the pronunciation of Japanese and East Asian characters. <ruby> can be used together with <rt> and/or <rp>.

The <ruby> tag entails one or more characters that require an explanation or pronunciation, the <rt> element provides the explanation or pronunciation, and the optional <rp> element provides what to show for browsers that lack support for annotations.


<!-- Contents go here -->

<ruby> wraps around the text that needs annotation.


This following example shows <ruby> being used with <rt> and <rp> tag:

<ruby> ゆきひろ まつもと <rp>(</rp><rt>Yukihiro Matsumoto</rt><rp>)</rp> </ruby>

This will display the following:

HTML ruby tag example

All contributors

Looking to contribute?

Learn HTML on Codecademy