HTML Tutorial

HTML Tag: <dt>

Usage of <dt>

The <dt> tag is used to define a term in a definition list. It stands for "definition term". The term is typically followed by a <dd> (definition description) tag that contains the definition.

Attributes of <dt>

  • global: Attributes that are common to all HTML elements
  • None: <dt> does not have any specific attributes

Examples with <dt>

<dl>
  <dt>Term 1</dt>
  <dd>Definition 1</dd>

  <dt>Term 2</dt>
  <dd>Definition 2</dd>

  <dt>Term 3</dt>
  <dd>Definition 3</dd>
</dl>

Exploring the <dt> Tag

This example demonstrates the usage of <dt> within a definition list:

<!DOCTYPE html>
<html>
<body>

<h1>Glossary of Terms</h1>

<dl>
  <dt>HTML</dt>
  <dd>Hypertext Markup Language</dd>

  <dt>CSS</dt>
  <dd>Cascading Style Sheets</dd>

  <dt>JavaScript</dt>
  <dd>A scripting language for websites</dd>
</dl>

</body>
</html>

When viewed in a web browser, this example will display a list of terms and their corresponding definitions