By using this site you agree to the use of cookies by Brugbart and our partners.

Learn more

An Introduction to XML Sitemaps

Short Introduction on how to create XML Sitemaps.

Edited: 2012-07-10 06:24

The XML sitemap allows to share your content easily with search engines. Its often recommended to provide search engines with a sitemap, both because it will be quicker for them to discover your content, but also because it may share otherwise inaccessible content and areas of your website.

Even when you have taken care to make sure that all content, is accessible from at least one link on your site, its still a good idea to include a sitemap, since it allows search engines to quickly index your content, without having to crawl its way to it first.

Sitemap example

The below is an example of a simple sitemap, where each page on your site, will be marked up using the URL element

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
   <url>
      <loc>http://www.brugbart.com/</loc>
      <lastmod>2005-01-01</lastmod>
   </url>
</urlset>

So if you want to add additional URLs, you simply need to add more URL elements. I.e.

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
   <url>
      <loc>http://www.brugbart.com/</loc>
      <lastmod>2005-01-01</lastmod>
   </url>
   <url>
      <loc>http://brugbart.com/Infrastructure/privacy</loc>
      <lastmod>2011-01-08</lastmod>
   </url>
</urlset>