HTML - Tag Reference



HTML tags are similar to keywords, which specify how a web browser will format and display content. A web browser can differentiate between simple content and HTML content with the use of tags. The major components which are essential for the HTML tag are the opening tag and the closing tag. However, some tags in HTML are not closed.

An HTML document is viewed by a web browser from left to right and top to bottom. To generate HTML documents and render their structures, utilize HTML tags. Every HTML tag has a unique set of features.

Basic Tags

Following are the basic tags that are listed below −

Sr.No Basic Tag & Description
1 <!--...-->

Specifies a comment.

2 <!DOCTYPE>

Specifies the document type.

3 <html>

The html tags are the container that contains all the other HTML tags.

4 <head>

Specifies information about the document.

5 <title>

Specifies the document title.

6 <body>

Specifies the body element.

7 <h1> to <h6>

Specifies header 1 to header 6.

8 <p>

Specifies a paragraph.

9 <br>

Inserts a single line break.

10 <hr />

Specifies a horizontal rule

Formatting Tags

Following are the Formatting tags that are listed below −

Sr.No Formatting Tag & Description
1 <abbr>

Specifies an abbreviation

2 <address>

Specifies an address element

3 <bdi>

Represents text that must be isolated from its surrounding for bidirectional text formatting. It allows embedding a span of text with a different, or unknown, directionality

4 <bdo>

Specifies the direction of text display.

5 <blockquote>

Specifies a long quotation.

6 <cite>

Specifies a citation.

7 <code>

Specifies computer code text.

8 <del>

Specifies deleted text.

9 <dfn>

Specifies a definition term.

10 <em>

Specifies emphasized text.

11 <i>

Specifies italic text.

12 <ins>

Specifies inserted text.

13 <kbd>

Specifies keyboard text.

14 <mark>

Specifies a text highlighted for reference purposes, that is for its relevance in another context.

15 <meter>

Specifies a scalar measurement within a known range (a gauge).

16 <pre>

Specifies pre formatted text.

17 <progress>

Specifies a completion progress of a task.

18 <q>

Specifies a short quotation.

19 <rp>

Specifies to show browsers that do not support the ruby element.

20 <rt>

Specifies an text ruby annotation.

21 <ruby>

Specifies an ruby annotation.

22 <s>

It is used to render text with a strike through.

23 <samp>

It is used to enclose the inline text that represents the sample output from a computer program or a script.

24 <small>

Specifies small text.

25 <strong>

Specifies strong text.

26 <sub>

Specifies subscripted text.

27 <sup>

Specifies superscripted text.

28 <template>

It is a mechanism for holding some client-side content hidden from the user when the page loads.

29 <time>

Specifies a date and time <details>.

30 <var>

Specifies a variable.

31 <wbr>

Indicates a potential word break point within a <nobr> section.

32 <b>

It is used to highlight the text and specify the bold text.

Forms and Input

Following are the Forms and Input Tag tags that are listed below −

Sr.No Forms and Input Tag & Description
1 <form>

Specifies a form.

2 <input>

Specifies an input field.

3 <textarea>

Specifies a text area.

4 <button>

Specifies a push button.

5 <select>

Specifies a selectable list.

6 <optgroup>

Specifies an option group.

7 <option>

Specifies an option in a drop-down list.

8 <label>

Specifies a label for a form control.

9 <fieldset>

Specifies a fieldset.

10 <legend>

Specifies a title in a fieldset.

11 <datalist>

A list of options for input values.

12 <output>

Specifies the result of a calculation.

Images

Following are the Image tags that are listed below −

Sr.No Images & Description
1 <img>

Specifies an image.

2 <map>

Specifies an image map.

3 <area>

Specifies an area inside an image map.

4 <canvas>

For making graphics with a script.

5 <figcaption>

Specifies a caption for a <figure> element.

6 <figure>

Specifies self-contained content.

7 <picture>

Picture permits the specification of multiple images that are intended to more accurately fill the browser viewport.

8 <svg>

It is a modular language used to describe visuals

Audio/Video

Following are the Audio/Video tags that are listed below −

Sr.No Audio/Video & Description
1 <audio>

Specifies a sound content.

2 <source>

Specifies a media resources for media elements, defined inside video or audio elements.

3 <track>

Specifies a text tracks used in mediaplayers.

4 <video>

Specifies a text tracks used in media players

links

Following are the link tag that are listed below −

Sr.No Links & Description
1 <a>

Specifies an anchor.

2 <link>

Specifies a resource reference.

3 <nav>

Specifies a section that contains only navigation links.

Lists

Following are the list tags that are listed below −

Sr.No Lists & Description
1 <ul>

Specifies an unordered list.

2 <ol>

Specifies an ordered list.

3 <li>

Specifies a list item.

4 <dl>

Specifies a definition list.

5 <dt>

Specifies a definition term.

6 <dd>

Specifies a definition description.

Tables

Following are the table tags that are listed below −

Sr.No Tables & Description
1 <table>

Specifies a table.

2 <caption>

Specifies a table caption.

3 <th>

Specifies a table heading.

4 <tr>

Specifies a table row.

5 <td>

Specifies a table cell.

6 <thead>

Specifies a table header.

7 <tbody>

Specifies a table body.

8 <tfoot>

Specifies a table footer.

9 <col>

Specifies attributes for table columns.

10 <colgroup>

Specifies groups of table columns

Styles and Semantics

Following are the Styles and Semantics tags that are listed below −

Sr.No Styles and Semantics & Description
1 <style>

Specifies a style definition.

2 <div>

Specifies a section in a document.

3 <span>

Specifies a section in a document.

4 <header>

Specifies a header for a document or section..

5 <footer>

Specifies a footer for a document or section..

6 <main>

Specifies the main or important content in the document. There is only one <main> element in the document.

7 <section>

Specifies a section in a document.

8 <article>

Specifies an article.

9 <aside>

Specifies some content loosely related to the page content. If it is removed, the remaining content still makes sense.

10 <details> It is used to create a disclosure widget that contains some information, and is visible when the widget is toggled to the "open" state.

11 <dialog>

Specifies a dialog box or window.

12 <summary>

Specifies a summary, caption, or legend for a given <details>

13 <data>

The HTML data tag is used to link the given piece of content with the machine-readable translation.

Meta Info

Following are the meta-info tags that are listed below −

Sr.No Meta Info & Description
1 <meta>

Specifies meta data of an html document which is not displayed on the page.

2 <base>

Specifies a base URL for all the links in a page.

Programming

Following are the programming tags that are listed below −

Sr.No Programming & Description
1 <script>

Specifies a script.

2 <noscript>

Specifies a noscript section.

3 <embed>

Specifies a container for an external (non-HTML) application.

4 <object>

Specifies an embedded object.

Advertisements