Advertisement

HTML <title> tag

Examples

A simple HTML document, with the minimum required tags:

<html>
 
  <head>
    <title>XHTML Tag Reference</title>
  </head>

  <body>
    The content of the document......
  </body>

</html>

Try it yourself

Browser Support

IE Firefox Chrome Safari Opera

All browsers support the <title> tag.

Definition and Usage

<Title> element defines the title of the document.

The browser will use a special way to the title, and it is usually placed on the title bar or status bar of the browser window. Similarly, when a document is added to the user's list of links or bookmarks or favorites list, the title will become the default name of the document link.

Differences between HTML and XHTML before

NONE

Tips and Notes

Tip: <title> tag is something <head> tag only requirement contains.

Standard property

<Title> tag supports the following standard attributes:

Attributes value description
dir
  • rtl
  • ltr
Predetermined direction of the text element content.
lang language_code Provision element content language code.
xml: lang language_code Provisions XHTML document element content language code.

DTD: Allows the label indicates what the XHTML 1.0 DTD. S = Strict, T = Transitional, F = Frameset.

For more information about the HTML standard attributes, visit the standard attributes .

Global Properties

<title> tag supports HTML in the global properties .

Further reading: What is the title of?

Be sure to select a correct title, which define the document and ensure that it can effectively use the Web is very important.

Remember that the user can use in any order, independently access the document set for each document. Therefore, the title of the document should not only be based on the context of the definition of other documents, but also to show its own characteristics.

The title contains a reference to the document ordering is usually not a good title. For example, like "Chapter XVI" or "Part V" such a title, the reader understand the content useless. More descriptive title like "Chapter XVI: HTML title" or "Part V: How to use the title", this title is not only the expression of a large document in its centralized location, further illustrate specific documents content to attract readers more interested in reading.

Self-referential title nor useful. Like "Home" This title and the content is no relationship, there are similar "feedback page" or the "common link" and so on. You should be designed to convey a certain content and purpose of the title, with this title so readers can determine whether the need to access this page. "For more information HTML <title> tag," which is a descriptive title, there are similar "HTML <title> tag feedback page" and so on.

People often spend a lot of time to create Web documents, but often unattractive or just because a meaningless title, but all these efforts wasted. When the user automatically collect special link software more and more popular on the Web, only the title of the page associated with the page will be used as a descriptive term, it is inserted into the large link database. So, how we can not stress that too much: Make for yourself every document carefully choose a descriptive, practical and context-independent title.

Related Pages

HTML DOM Reference Manual: the Title objects