Wednesday, December 21, 2016

Do I need to build a Sitemap for my Website?

What is a sitemap?

Human readable sitemaps are static HTML files that outline the first and second level structure of a Web site. The original purpose of a site map was to enable users to easily find items on the Web site.  But the purpose grew over time to became useful as a shortcut method to help search engines find and index all the parts of a site.

Now, we have an XML sitemap, which effectively provides an easy-to-read link dump for the spiders to index. Some Web browsers can display an XML sitemap for users to read as well, you should offer both kinds of site maps (HTML and XML) if you want to be sure to cover both the search engines and your users.


What is a Sitemap used for?

Building a website can be a long tedious process, which can be more complicated by the huge amount of information that should be organized before including in your website. Some designers will start by creating  wireframes and mockups.  But for the rest of us it a lot easier to just build a sitemap to use as a guide to build the structure and pages needed for your website.  The key factor is to keep you organized and to keep you from duplicating pages.

So What are all the types of sitemaps?

  1. standard HTML sitemap - Human readable list of your website links
  2. Text Sitemaps - Text sitemaps contain one website url per line. Many search engines including Google and Yahoo can scan text sitemaps. 
  3. Standard XML sitemap - Started by Google in 2005. The protocol of XML sitemaps also defines autodiscovery. It allows search engines can automatically discover website via the XML sitemaps.
  4. Image sitemap - Use to build a lost of images for the search engine like Google.
  5. Video sitemap - used to build list of your video for search engine like Google.
  6. Mobile sitemap - used to build list of mobile only pages for search engine like Google.  Useful for AMP , WAP or cHTML sites.
  7. News sitemap - This is used by Google News and is a great way to index your files for Google News.
  8. RSS Feeds as Sitemaps - RSS protocol is often used in feed files for blogs and forums. The RSS file format uses XML and has evolved over multiple versions and names, all fairly compatible with each other.
  9. ROR Sitemaps - ROR expands on the RSS protocol with its own extensions. Not currently supported by major search engine.

So Which sitemaps do I really need?

Basically there are only two sitemaps that you need to build.  Any of the other formats are optional & mostly used by bigger websites.
You only need 
  1. sitemap.html for our guests.
  2. sitemap.xml that you should submit to Google and the other search engines.  
You can also add this line below to your robots.txt file too.
Sitemap: http://www.your-domain.com/sitemap.xml


Here are examples of each sitemap formats:

Standard HTML sitemap  (sitemap.html)

<html lang="en">
  <head>This is a site map</head>
  <body>
    <h1>Your Site Name's HTML sitemap</h1>
    <p>Listed below are our the links for our website.</p>
    <a href="index.html" title="Title of your page">Home page</a>
  </body>
</html>
Text sitemap  (sitemap.txt)
http://www.your-domain.com/
http://www.your-domain.com/images/
http://www.your-domain.com/cgi-bin/


Standard XML sitemap (sitemap.xml)

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
  <url>
    <loc></loc>
    <priority>1.0</priority>
    <changefreq>weekly</changefreq>
    <lastmod>2007-06-18</lastmod>
  </url>
  <url>
    <loc>blogs/</loc>
    <priority>0.8</priority>
    <changefreq>weekly</changefreq>
    <lastmod>2007-06-21</lastmod>
  </url>
</urlset>


Image sitemap (sitemap-image.xml)

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:image="http://www.google.com/schemas/sitemap-image/1.1">
  <url>
    <loc>http://www.your-domain.com/</loc>
    <priority>1.0</priority>
    <image:image>
      <image:loc>http://www.your-domain.com/1.png</image:loc>
      <image:title>image 1 title</image:title>
      <image:caption>image 1 caption</image:caption>
    </image:image>
    <image:image>
      <image:loc>http://www.your-domain.com/2.png</image:loc>
      <image:title>image 2 title</image:title>
      <image:caption>image 2 caption</image:caption>
    </image:image>
  </url>
</urlset>

Video sitemap  (sitemap-video.xml)

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:video="http://www.google.com/schemas/sitemap-video/1.1">
  <url>
    <loc>http://www.microsystools.com/products/sitemap-generator/videos/sitemap-builder-sitemaps-tool/</loc>
    <video:video>
      <video:player allow_embed="yes">http://www.youtube.com/v/xZ-LrxSA3Yo?fs=1</video:player>
      <video:thumbnail_loc>http://i1.ytimg.com/vi/xZ-LrxSA3Yo/default.jpg</video:thumbnail_loc>
      <video:title>Sitemap Generator - Videos [ sitemap builder sitemaps tool ]</video:title>
      <video:description>Video: Sitemap Generator - build sitemaps quick demonstration</video:description>
      <video:category>sitemaps</video:category>
      <video:tag>a1</video:tag>
      <video:tag>sitemap</video:tag>
      <video:tag>generator</video:tag>
      <video:tag>google</video:tag>
      <video:tag>xml</video:tag>
      <video:tag>html</video:tag>
      <video:tag>sitemaps</video:tag>
    </video:video>
    <video:video>
    ...
    </video:video>
  </url>
  <url>
  ...
  </url>
</urlset>

Mobile sitemap (sitemap-mobile.xml)

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:mobile="http://www.google.com/schemas/sitemap-mobile/1.0">
  <url>
    <loc>http://example.mobi/</loc>
    <priority>1.0</priority>
    <mobile:mobile/>
  </url>
</urlset>

News sitemap (sitemap-news.xml)

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:n="http://www.google.com/schemas/sitemap-news/0.9">
  <url>
    <loc>http://your-domain.com/</loc>
    <n:news>
      <n:publication>
        <n:name>News paper, blog or similar name</n:name>
        <n:language>en</n:language>
      </n:publication>
      <n:publication_date>2008-12-30T00:00:00+00:00</n:publication_date>
      <n:keywords>2008,news,xml,sitemap,example,keywords,generated</n:keywords>
      <n:title>News Article Title</n:title>
    </n:news>
  </url>
</urlset>


RSS Feeds as Sitemaps  (sitemap.rss)

<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0">
  <channel>
    <title>Website title</title>
    <link>http://www.your-domain.com</link>
    <generator>Sitemap Generator</generator>
    <lastBuildDate>Tue, 13 Mar 2007 22:28:20 GMT</lastBuildDate>
    <item>
      <title>Page 1</title>
      <link>http://www.your-domain.com/page1.html</link>
    </item>
    <item>
      <title>Page 2</title>
      <link>http://www.your-domain.com/page2.html</link>
    </item>
  </channel>
</rss>

ROR Sitemaps (sitemap.ror)

<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:ror="http://rorweb.com/0.1/">
  <channel>
    <title>Website title</title>
    <link>http://www.your-domain.com</link>
    <generator>A1 Sitemap Generator</generator>
    <lastBuildDate>Thu, 21 Dec 2016 08:01:30 GMT</lastBuildDate>
    <item>
      <title>Page 1</title>
      <link>http://www.your-domain.com/page1.html</link>
      <ror:keywords>page1-keyword1, page1-keyword2, page1-keyword3</ror:keywords>
      <ror:updatePeriod>day</ror:updatePeriod>
    </item>
    <item>
      <title>Page 2</title>
      <link>http://www.your-domain.com/page2.html</link>
      <ror:keywords>page2-keyword1, page2-keyword2, page2-keyword3</ror:keywords>
      <ror:updatePeriod>day</ror:updatePeriod>
    </item>
  </channel>
</rss>


The Sitemap Wrap up

Finally a sitemap can save you a lot of time by not creating unnecessary pages, or building sites that are overly complicated than needed.  Take time to sit down and create your websites content and figure out what is necessary.  Planning is key to saving time.  

You can find a number of great company on Google or other search engine.