How to Create an XML Sitemap

How to Create an XML SitemapWe all know how impossible it can be to find your way around anywhere without a map. So, it is with this logic in mind that we should be looking at XML sitemaps, because without these maps, it can be very hard for Google to find all of the associated pages within your website. 

While XML Sitemaps are important to have for your content, the good news is that they are quick and easy to set up and submit to Google. 

The Basics of an XML Sitemap

An XML Sitemap is an XML file that contains a master list of all of the important content held on your website. This means that any content that you would want to show up in Google or other search engines should be compiled in your sitemap. 

As a note, sitemaps cannot have more than 50,000 URLs or be over 50mb. So, if your sitemap will exceed either of these limits, you will have to submit multiple sitemaps. 

What is in an XML Sitemap

The first thing to remember when looking at sitemaps is that they are built to be read by search engines, not human operators – so they may not be the most friendly thing to read for beginners. 

Here is a breakdown of the pieces of an XML Sitemap.

The XML Declaration

This declaration lets the search engine know that they are looking at an XML file. This also gives the version of XML and the character encoding used. The version you want to be using is 1.0, and the encoding should be UTF-8.

The URL Set

This is what is known as a container. It is where all of the URLs will be stored for the sitemap. This allows search engines to know which protocol standard should be used. A lot of sitemaps use Sitemap 0.90 standard, which is a system supported by major search engines such as Google, Yahoo!, and Microsoft, as well as many others. 

The URL

The parenting tag for each URL must be the specific location of the URL within a nested tag. These must be absolute canonical URLs and not relative ones. 

Why does your website need a sitemap?

The way search engines like Google discover new content is by crawling the internet. When it is crawling pages it not only takes a look at internal links on the website but external ones, as well. Because of this, Google can still manage to appropriately index URLs that are not part of the search index for certain websites, however it is unable to find all of the available content through this method. For example, if an non-indexed URL is not linked to another source that is already known, Google will not be able to find it. This is where your sitemap comes into play.

Your sitemap will tell Google and other top search engines where your most important content and pages are within your website, which will allow the search engines to crawl the content and index it. This is vital for the growth and health of your website and content because Google and other search engines cannot rank your content without it first being indexed. 

Creating an XML Sitemap

When it comes to creating a sitemap, there are a lot of content management systems (CMS) that will generate a sitemap for you automatically. These CMS will automatically adjust your sitemap whenever you make additions to, or remove content from your website. However, if you have a CMS that does not automatically update your sitemap, there are plugins that you can use to help build the sitemap. 

Building a sitemap with WordPress

While a large portion of websites are powered by WordPress, the CMS does not automatically create a sitemap for you. However, there are plugins like Yoast SEO that can help you build one for your site.

Running this plugin in WordPress will automatically build a sitemap for you. This will also allow you to include or exclude specific content from your sitemap (specific tags or categories). You can also use this method to exclude certain posts and pages from the sitemap. 

It is important to know that you should only ever exclude pages, tags and content that you do not want to show up in search engine results. 

Creating a sitemap with Wix

Wix will automatically create a sitemap for you. However, with this CMS you do not have a lot of control over what is or isn’t included in your sitemap. But you can turn the “show this page in search results” off within the SEO setting of the CMS. 

Creating a sitemap with Squarespace

Like Wix, Squarespace will automatically generate a sitemap for you. However, you have limited ability to exclude pages from your sitemap. 

If you are looking for a Digital Marketing Agency who specializes in SEO then contact us today!