HTML <tt> tag

Updated: 11/13/2018 by Computer Hope
HTML tt tag

When writing in HTML (hypertext markup language), the <tt> tag was used to designate inline teletype text. It was intended to style text as it would appear on a fixed-width display, using the browser's default monotype font. The following sections contain information about this tag, including an example of it in use, and related attributes and browser compatibility.

Note

This tag is deprecated, use the <code> tag instead.

Example of <tt> code

<p>Some normal text. <tt>Some teletype text.</tt></p>

Example result

Some normal text. Some teletype text.

Attributes

All HTML tags support standard attributes that define the settings of an HTML element. Unlike other HTML tags, the <tt> tag has no unique attributes.

Compatibility

Edge Internet Explorer Firefox Safari Opera Chrome
All versions * All versions * All versions * All versions * All versions * All versions *

*Until it is removed in a future version of HTML

Browser, Compatibility, Container tag, Font, HTML kbd tag, HTML var tag, Inline, Web design terms