Search this site...

Quick HTML tags reference

The following table lists HTML tags (in alphabetical order) with:

  • HTML tag name
  • description of the HTML tag
  • indication whether or not closing tag is required
  • attributes of each HTML tag
Table 1 HTML Tags - Quick Reference
HTML Tag Tag Name Description Closing Tag Attributes
<!--HTML comment text-> Comment Identifies sections of HTML code No N/A
<a> Anchor Creates hypertext links Yes target, href, name
<address> Address Displays text in italics Yes style, id, class, lang, dir, title
<applet> Applet Runs Java applets Yes alt, code, align, width, height, codebase, hspace, vspace
<area> Area Creates a clickable area (also known as hotspot) on an imagemap No coords, href, nohref, shape
<B> Bold Make text bold Yes style, id, class, lang, dir, title
<blockquote> Block quote Indents text from both left and right margins Yes cite, style, id, class, lang, dir, title
<body> Body Defines the body of an HTML document Yes backGround, bgColor, aLink, vLink, text
<br> Line break Ends the current line. No clear, style, id, class, lang, dir, title
<caption> Caption creates a caption for an HTML table Yes align, style, id, class, lang, dir, title
<center> Center Centers text Yes align, style, id, class, lang, dir, title
<cite> Citation Used for indicating a source used as a citation Yes align, style, id, class, lang, dir, title
<code> Code Displays text in a fixed width font Yes align, style, id, class, lang, dir, title
<div> Logical division Divides an HTML document into logical sections Yes align, style, id, class, lang, dir, title
<dl> Definition list Creates a definition list Yes align, style, id, class, lang, dir, title
<dt> Definition term Creates a definition list term Yes style, id, class, lang, dir, title
<embed> Embed inserts media files (i.e, background sounds) into web pages No src, autostart, loop, volume, width, height
<font> Font sets font size, color, and face Yes size, color, face
<form> Form Creates a form for a user to enter data Yes action, method, target, style, id, class, lang, dir, title
<frame> Frame Defines a frame (window) No src, name, marginwidth, marginheight, scrolling, noresize
<frameset> Frameset Defines the frameset Yes rows, cols, border
<h1> Heading level 1 Creates a first-level heading Yes align, style, id, class, lang, dir, title
<h2> Heading level 2 Creates a second-level heading Yes align, style, id, class, lang, dir, title
<h3> Heading level 3 Creates a third-level heading Yes align, style, id, class, lang, dir, title
<h4> Heading level 4 Creates a fourth-level heading Yes align, style, id, class, lang, dir, title
<h5> Heading level 5 Creates a fifth-level heading Yes align, style, id, class, lang, dir, title
<h6> Heading level 6 Creates a sixth-level heading Yes align, style, id, class, lang, dir, title
<head> Head or header Defines head section of an HTML document Yes lang, dir
<hr> Horizontal rule Creates a horizontal line across a web page No size, width, align, noshade, align, style, id, class, lang, dir, title
<html> HTML Contains the head and body section of an HTML document (web page) Yes lang, dir
<i> Italic Makes text italic Yes style, id, class, lang, dir, title
<img> Inline image Inserts an inline image into an HTMl document No src, height, width, alt, title, border, align, hspace, vspace
<input> Form input Creates form fields such as text boxes, check boxes, submit button, and reset button No type, value, name, size, maxlength, checked, align, accept, readonly, style, id, class, lang, dir, title
<lh> List heading Creates a list heading Yes type, value, style, id, class, lang, dir, title
<li> List item Creates a list item Yes type, value, style, id, class, lang, dir, title
<link> Link Creates hyperlinks to documents or files, including style sheets No rel, rev, href, target, type, media, charset, style, id, class, lang, dir, title
<map> Map Used with a client-side imagemap Yes name, style, id, class, lang, dir, title
<meta> Meta Describes information about an HTML document No name, content, http-equiv, scheme, lang, dir
<ol> Ordered list Creates an ordered list Yes type, style, id, class, lang, dir, title
<option> Option Defines an option item for a selction list Yes value, selected, style, id, class, lang, dir, title
<p> Paragraph Creates a paragraph Yes width, style, id, class, lang, dir, title
<pre> Preformatted text Creates a section of preformatted text Yes width, style, id, class, lang, dir, title
<script> Script Specifies the scripting language used in the HTML document Yes language
<select> Form select Creates a selction menu in an HTML form Yes name, size, disabled, multiple, style, id, class, lang, dir, title
<strike> Strike-through Draws a line through text Yes style, id, class, lang, dir, title
<sub> Subscript Creates a subscripted text Yes style, id, class, lang, dir, title
<sup> Superscript Creates a superscript text Yes style, id, class, lang, dir, title
<table> Table Creates a table in an HTML document Yes align, width, cellpadding, cellspacing, border, bgcolor, style, id, class, lang, dir, title
<td> Table data Creates a column or cell in a table Yes bgcolor, rowspan, colspan, nowrap, valign, width, height, style, id, class, lang, dir, title
<textarea> Form text area Creates a text area in form Yes name, rows, cols, disabled, readonly, style, id, class, lang, dir, title
<th> Table heading Creates a cell as a table heading (displays text as centered and bold) Yes bgcolor, rowspan, style, id, class, lang, dir, title
<title> Title Creates HTML document's title (displayed at the top of the browser window) Yes lang, dir
<tr> Table row Creates a table row Yes bgcolor, align, valign, style, id, class, lang, dir, title
<u> Underlined Underlines text Yes style, id, class, lang, dir, title
<ul> Unordered list Creates an unordered list Yes style, id, class, lang, dir, title