How to Set a Title in HTML: 9 Steps (with Pictures) (2024)

  • Categories
  • Computers and Electronics
  • Internet
  • Website and Blog Creation
  • Markup Languages
  • HTML

Download Article

A simple walkthrough for giving your HTML code a title

Author Info

Last Updated: April 19, 2023Tested

Download Article

  • Creating the HTML Layout
  • |
  • Adding the Title Tag
  • |
  • Testing the Code
  • |
  • Video
  • |

Every web page needs a title. Why doesn't yours? One of the major tag pairs in HTML is the <title></title> tags; the title tag affects several functions of websites, from the default bookmark titles through to flashing words drawing your attention back to the site, even when in a different tab.

Things You Should Know

  • Create your HTML in a program like Atom, Brackets, TextEdit, or Notepad++.
  • Add the <title>Something</title> Title Tag to your code.
  • Change "Something" to the title you want and save the file.

Part 1

Part 1 of 3:

Creating the HTML Layout

Download Article

  1. 1

    Open a text editing program (or IDE) such as Atom, Brackets, or even TextEdit or Notepad++.

  2. 2

    Create the <html> body. Using the <html> tags, create a .html file with either tag on a new line. Make sure to close the tag with </html>.

    Advertisem*nt

  3. 3

    Add the <head> section. Placing the <head> tags in between the <html> tags, define the head (metadata section) section. Make sure to close the tag with </head>.

  4. 4

    Add the <body> section. Below the closing </head> tag and above the closing </html> tag, add the <body> (content section) tags. Make sure to close the tag with </body>.

    • Optionally, add some 'test' code in the body (or content) section to make sure that you've coded it correctly. If the content shows, it means that the code is parsing (loading). If not, it means that you may have made a typo or some other thing that is not letting it load.
  5. Advertisem*nt

Part 2

Part 2 of 3:

Adding the Title Tag

Download Article

  1. 1

    Add a <title> tag in the head (metadata) section.

    • Make sure to close the tag with </title>. These two tags can be on the same line. In between the starting and closing title tags, write what you want your title to say.

Part 3

Part 3 of 3:

Testing the Code

Download Article

  1. 1

    Save your file to an easily accessible location. Name your file as something.html, replacing something with what you wish. Remember that the index.html file is the 'home' or 'landing' page of your website.

  2. 2

    Open your page in your preferred browser. Browsers like Google Chrome, or Mozilla Firefox are good for front-end website development. Go ahead and open your .html file. You can use short keys like Cmd+O or Ctrl+O to open the file in most browsers.

  3. 3

    Look at the top of the tab for your title. If your desired title shows, the code has loaded and worked! If not, and it shows your filename instead (something.html), you may have made a mistake; check your code for typos then try again.

  4. 4

    Sit back and admire your work. You've just taken the first step to a fully functional website.

  5. Advertisem*nt

Search

Add New Question

  • Question

    How do I insert the first level heading?

    How to Set a Title in HTML: 9 Steps (with Pictures) (13)

    Shehriar Ahmad Awan

    Community Answer

    You can do it using the H1 tag.

    Thanks! We're glad this was helpful.
    Thank you for your feedback.
    If wikiHow has helped you, please consider a small contribution to support us in helping more readers like you. We’re committed to providing the world with free how-to resources, and even $1 helps us in our mission.Support wikiHow

    YesNo

    Not Helpful 7Helpful 4

Ask a Question

200 characters left

Include your email address to get a message when this question is answered.

Submit

      Advertisem*nt

      Video

      Tips

      Submit a Tip

      All tip submissions are carefully reviewed before being published

      Submit

      Thanks for submitting a tip for review!

      You Might Also Like

      How toLearn HTMLHow toCreate a Simple Web Page with HTML
      How toWrite an HTML PageHow to Change Text Color in HTML and CSSHow toUse Font Color Tags in HTMLHow toInsert Spaces in HTMLHow toRun a HTML File in Visual Studio Code4 Ways to Add a Link to a PictureHow toChange the Button Color in HTMLHow toGet the Hex Code of a Color on Your Computer ScreenHow toWrite HTML CodeHow toCreate an Email Link in HTMLHow toRun a HTML FileHow toInsert Images with HTML

      Advertisem*nt

      About This Article

      Tested by:

      wikiHow Technology Team

      wikiHow is a “wiki,” similar to Wikipedia, which means that many of our articles are co-written by multiple authors. To create this article, volunteer authors worked to edit and improve it over time. This article has been viewed 65,956 times.

      How helpful is this?

      Co-authors: 4

      Updated: April 19, 2023

      Views:65,956

      Categories: HTML

      • Print
      • Send fan mail to authors

      Thanks to all authors for creating a page that has been read 65,956 times.

      Is this article up to date?

      Advertisem*nt

      How to Set a Title in HTML: 9 Steps (with Pictures) (2024)
      Top Articles
      Latest Posts
      Article information

      Author: Msgr. Refugio Daniel

      Last Updated:

      Views: 5818

      Rating: 4.3 / 5 (54 voted)

      Reviews: 85% of readers found this page helpful

      Author information

      Name: Msgr. Refugio Daniel

      Birthday: 1999-09-15

      Address: 8416 Beatty Center, Derekfort, VA 72092-0500

      Phone: +6838967160603

      Job: Mining Executive

      Hobby: Woodworking, Knitting, Fishing, Coffee roasting, Kayaking, Horseback riding, Kite flying

      Introduction: My name is Msgr. Refugio Daniel, I am a fine, precious, encouraging, calm, glamorous, vivacious, friendly person who loves writing and wants to share my knowledge and understanding with you.