XML Sitemap Guide

A XML sitemap is as the name implies a map of your websites pages in XML, This is a wonderful way to tell search engine spiders and robots where pages are located on your web page and how often they are updated. Including a sitemap with your website is a great way to ensure that search engines index your site correctly. The sitemap file is most often called sitemap.xml and is located in the root folder of your website however it can be called anything and can be located anywhere that is publicly accessible

If you are using a content management system like Joomla or a blogging engine like WordPress then you will be able to generate your sitemaps automatically using 3rd party addons which are available in their respective repositories. For example I use the XMAP component for Joomla to generate the sitemaps for netlife.co.za

If however you are not using a system that allows for automatic sitemap generation there are other options available to create a sitemap. There are many online sitemap generators which will allow you to create a sitemap simply by entering your website URL. These generators usually crawl your site and general the sitemap for you. The only real downside is that you would have to manually update the the file each time you make a change.

Alternatively you can install a sitemap generator script on your website which can be scheduled to automatically update the sitemap at defined intervals through cron. This is probably the best solution however you will need access to install scripts.

The last resort would be manual creation of the sitemap, the layout of the XML file is very simple and could be used easily for small websites which are static. An example of the sitemap.org protocol xml code is as follows;

<?xml version=”1.0″ encoding=”UTF-8″?>
<urlset xmlns=”http://www.sitemaps.org/schemas/sitemap/0.9″>
<url>
<loc>http://www.example.com/</loc>
<lastmod>2005-01-01</lastmod>
<changefreq>monthly</changefreq>
<priority>0.8</priority>
</url>
</urlset>
If you are still unable to create a sitemap you should not panic, the world will still find your site without one. You will just not have as much control over the process or be able to track errors as easily. I really do suggest using a sitemap if possible but the world will not end if you do not have one

Leave a Reply