XML Sitemap

What is a Sitemap

A sitemap is a structured list of the pages that make up a website. Typically, you'll find two different types of website sitemaps:

  • HTML Sitemaps are coded in HTML via anchor links and are more for visitors to use a gateway to all of the pages of the website.
  • XML Sitemaps are XML files used by search engines to crawl and index websites. Additional elements can be added to them that will instruct the search engine bots to crawl the pages in a particular manner.

From HTML to XML - A Tale of Two Sitemaps

Before search engines modern level of complexity. Site owners would create an HTML sitemap (gateway page) that would link to all of the various pages throughout their website. As you can imagine, the sitemap page would be huge depending on the size of their website. When a search engine bots would crawl a sitemap, they would acquire a gateway to every page on a website. Early SEOs who struggle to have page discovered and indexed, found sitemaps to be very important. It was critical to include newly published pages in hopes they would be crawled and indexed quickly.

As websites aged, sitemaps grew. Eventually, they offered very little benefit to visitors as the blotted sitemaps were confusing and cluttered. Site owners primarily viewed them as a checklist item needed for SEO.

In June of 2005 Google introduced Sitemap 0.84, which allowed site owners to submit lists of URLs for the search engine to crawl. Google's project eventually evolved into what XML Sitemaps are today. A structured file that is easy to generate and consists of every page on a website with instructions on how the pages should be crawled. In today's world of SEO, it would be very difficult to have a website rank well without the use of an XML Sitemap. When conducting SEO audits, the sitemap is one of the highest priority items to check for and to ensure it is coded and updated properly.

You may still find a few old fashion HTML sitemaps in the wild. By no means am I saying HTML sitemaps are bad. They can be outstanding additions to a website's navigation if they are designed to benefit users. However, the old way just doesn't work anymore.

Advertisements

Structure of an XML Sitemap

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
   <url>
      <loc>https://www.banedigitalmarketing.com/</loc>
      <lastmod>2020-01-07</lastmod>
      <changefreq>weekly</changefreq>
      <priority>0.75</priority>
   </url>
   <url>
      <loc>https://www.banedigitalmarketing.com/search-engine-optimization/</loc>
      <lastmod>2020-01-08</lastmod>
      <changefreq>monthly</changefreq>
      <priority>0.5</priority>
   </url>
   <url>
      <loc>https://www.banedigitalmarketing.com/search-engine-optimization/what-is-an-xml-sitemap/</loc>
      <lastmod>2020-01-10</lastmod>
      <changefreq>daily</changefreq>
      <priority>1.0</priority>
   </url>
</urlset>

XML Sitemap Elements Explained

  • <?xml...?> Required
    This is the XML declaration that should be on the first line of code.
  • <urlset...> Required
    Declares the protocol standard used for the file and groups the URLs..
  • <url> Required
    URL of a page. The protocol must be entered for the listed URLs. (https://).
  • <lastmod> Optional
    Last day modified. Basically the date when the page was last edited. The date should be formatted using the W3C Datetime syntax (YYYY-MM-DD)
  • <changefreq> Optional
    Informs the bot on how often the page is changed. You can also look at this as how often should bots recrawl this page? Acceptable values: hourly, daily, weekly, monthly, yearly, always, and never.
  • <priority> Optional
    Ranking your pages by order of importance. The higher priority urls will be crawled first. Values can range from 0 to 1.0. If unset, the default priority will be 0.5.
Advertisements

Creating an XML Sitemap

There are many ways to automatically generate an XML Sitemap in a matter of minutes. Here are a few of my suggested ways to build your sitemap file:

  • GoogleSiteMap (MODx): The versatile extras allows you to fully customize your sitemap to ensure the highest quality result.
  • Yoast (Wordpress): This SEO plugin for wordpress automatically creates a dynamic XML sitemap.
  • xml-sitemaps.com: This is a browser-based free application that will scan your URL and create a XML sitemap for you. This is fine to do if you have a small site and plan to manage the sitemap by hand.

What to Do With an XML Sitemap

Once your XML sitemap has been created, we'll need to connect it to the search engines. There are a few ways of accomplishing this:

Google Search Console

As easy and entering the sitemaps URL and pressing Submit. After Google is connected to your sitemap, they start to provide you with metrics on how many pages are in the sitemap, how many are indexed, and if there are any issues with your sitemap.

BING Webmaster Tools

Essentially BING's equivalent to Google.

Robots.txt

You should always add the sitemap to your robots.txt files so other bots could find and crawl your site.

Syntax:

sitemap: https://www.banedigitalmarketing.com/sitemap.xml

Final Thoughts

You will be fighting an uphill battle if your website does not contain an XML Sitemap. I would highly suggest taking a moment to create a sitemap so your website could be properly crawled and indexed.

Advertisements