You wouldn’t design a new kitchen without creating a blueprint first, would you? So, why would you design a website without creating a sitemap?
If you want to launch a website that Google (and your potential customers) can discover, you’ll need a sitemap. Here’s how to create one.
What is a sitemap?
A sitemap is a file of code that lives on your web server and lists all of the relevant URLs your website is carrying. Your sitemap helps search engine web crawlers understand how your website is built so they can evaluate and rank it more easily.
People create sitemaps when they first design their website, add pages to it, and/or redesign it. It’s kind of like a floor plan for the site, which comes in handy whenever the site gets changed. Along with boosting search engine optimization (SEO), sitemaps can also help define a site’s navigation scheme so you avoid internal linking issues.
You might be thinking to yourself, “But I thought sitemaps were more visual, like a web.” That’s a visual sitemap, as opposed to an XML sitemap — the latter is what we’ve been talking about so far.
Visual sitemaps, on the other hand, are abstract sketches of your website’s structure, like the one below of Google’s website. They’re useful for the internal planning process, but it’s the XML sitemaps that are relevant to SEO best practices.
Image Credit: Wikimedia
XML sitemaps are designed specifically for search engines like Google, which need to be able to find webpages anchored within a website no matter how old or deeply nested they might be in that website’s domain.
Here’s an example of what an XML sitemap file might look like:
For this reason, an XML sitemap is a crucial component of a blog, where article pages are constantly bumped further back into the website’s archive as new content is published.
There are four major types of XML sitemaps you can create, each dedicated to a different type of media you might publish to your website:
- Image Sitemaps structure a website’s image content so that it ranks well in Google Images results.
- Video Sitemaps classify video content so that it ranks well in Google Videos results, as well as rich snippets in organic results.
- News Sitemaps describe your website’s news content so it’s more easily indexed in search results like Google News.
- Mobile Sitemaps optimize website content for mobile phones that don’t use native web browsers, which automatically produce web content in mobile form.
So, how do you structure your website’s XML sitemap? Let’s dive right in.
How to Create a Sitemap
1. Engage Your Marketing, Tech, IT, and Legal Teams
Typically, the teams involved in structuring a website’s sitemap are the marketing team, a technical team (whether that’s a team of developers or an agency), the IT team (or whoever controls your servers), and the legal team.
The Marketing Team
This marketing department is usually responsible for defining the structure of the site. Which pages need to link to one another? Should site visitors be able to get from the “About Us” page directly to the product page, for example? Whether they define the structure using a visual site map in PowerPoint or some other tool is up to them.
The Technical Team
A team of developers will then build an sitemap.xml file based on the structure defined by the marketing team.
The IT Team
Your support team usually gets involved too, assuming you’re using your own servers or some servers that IT controls. Remember, the sitemap lives on that server — so someone has to make sure it’s on there. If you’re working for an agency, they should be able to do this for you, too.
The Legal Team
Lastly, be sure you check with your legal team to make sure everything on your website is legally sound and you don’t have any outstanding copyright restrictions that could pass through your sitemap.
2. Research Each Search Engine’s Sitemap Requirements
When you first begin planning your sitemap, think about questions like: What are your website’s goals? Who’s your target audience, and what do they want to see?
You’ll also want to keep in mind each search engine’s requirements. The last thing you want to do is break the path of a visitor getting from a search engine to your website. Google’s, Bing’s, Yahoo!’s, and others’ requirements are fairly similar, but you’ll want to make sure you’re not breaking any specific requirements for any of them. This is especially true if you see a lot of your traffic is coming from a specific search engine.
To make sure you’re not breaking any rules, check out:
3. Define the Top-Level Navigation Structure
What do you want your homepage to link to? This will provide the foundation for your site’s structure, and will allow your site to grow.
In other words, a shallow website (one that requires three or fewer clicks to reach each page) is much better for SEO than a deep website, according to Search Engine Journal.
What are best practices for top-level navigation, you might be asking? Unfortunately, it’s hard to give general advice here as best practices can vary significantly by industry, company type, and so on. For inspiration from companies similar to yours, then take a look at Crayon: It has a huge library of real marketing designs you can filter by industry, traffic level, device, and so on. Check out high-traffic homepages in your industry to get a sense of their structure and get some ideas for yours.
4. Define the Second- and Third-Level Content
This is where creating visual sitemaps can come in handy. Once you’ve defined your homepage’s navigation structure, you’ll want to brainstorm and map out the pages that are two or three levels deeper into your website. This might be your “About Us” page, your team management page, your hiring page, your blog, and so on.
Depending on the complexity of your website, you may only need two levels, or you may need up to four. And as you think out the deeper parts of your website, you may find you need to tweak the top-level navigation — that’s okay.
5. Write the XML Sitemap and Submit it to Search Engines
Once you’ve planned out how your website will be organized, it’s time for the technical team to create the XML sitemap, put it on your web server, and submit it to each individual search engine (Google, Bing, Yahoo!, and so on).
When you first publish your website, and each time you go through a significant site redesign, someone on your team will have to submit the sitemap to each search engine (Google, Bing, Yahoo!, etc.) so that those search engines will be able to tell your homepage from your “About Us” page from your team management page.
Unless you’re using a platform that automatically updates your sitemap, you’ll need to update the sitemap yourself and resubmit any time you make a significant changes to your website.
(HubSpot customers: HubSpot will automatically generate your sitemap.xml file when you publish new pages and make changes to your site. But remember, you’ll still either have to rely on search engines to pick up new pages organically. That means if you’ve made a really significant change to your site’s structure, you might want to manually submit it.)
Best XML Sitemap Generators
- Screaming Frog
- Sitemap Writer Pro
- DYNO Mapper
- Rage Google Sitemap Automator
We recommend using a sitemap generator to build your XML sitemap. While the folks at Google no longer maintain their own sitemap generator, there are now plenty of free and downloadable tools you can use to create your own.
Once you’ve selected a sitemap generator, and created your sitemap in XML form, you’ll need to add it to your website’s source code and submit this sitemap to each search engine on which you want your website to be indexed.
Below are step-by-step instructions for submitting a sitemap to Google
How to Submit Your Sitemap to Google
- Sign in to Google Webmaster Tools.
- Click “Add a Property.”
- Enter the URL for your company and click “Continue.”
- Click “Crawl” on the lefthand sidebar and choose “Sitemaps.”
- Click “Add/Test Sitemap.”
- Enter “sitemap.xml” after your website’s domain name.
- Click “Submit Sitemap.”
1. Sign in to Google Webmaster Tools.
Google Webmaster Tools will be your dashboard for testing and submitting updated sitemaps to Google, so you can ensure Google is always aware of the latest pages published to your site.
For this step, you’ll first need to register your website with Google. Click the link at the beginning of this paragraph to get started.
2. Click “Add a Property.”
Once you’ve logged in to Google Webmaster Tools, click “Add a Property,” the square red button on the top righthand corner of your screen.
3. Enter the URL for your company and click “Continue.”
Type in the website whose sitemap you want to submit, exactly as it appears in your address bar. This website should just be the domain name — the parent URL to which all of your other webpages belong.
4. Click “Crawl” on the left-hand side of the page, and choose “Sitemaps.”
Once you add your website property, you’ll see a sidebar of options to the left. Click “Crawl” to reveal a dropdown of options and select “Sitemaps.”
5. Click “Add/Test Sitemap.”
To the right of your screen, you’ll see another red button for adding a new sitemap. Click it. If you already have a sitemap submitted, this button will simply say “Test,” allowing you to verify that Google has crawled your current sitemap.
6. Enter “sitemap.xml” after your website’s domain name.
Adding a new sitemap requires you to add a string of text to the end of your website’s domain. Think of it like a tracking tag, allowing Google to examine all the activity that takes place inside your website.
This sitemap tag is “sitemap.xml,” and you’ll want to add it to the end of your domain name. For example, if your domain is www.yourcompany.com, you’ll tag it like this: www.yourcompany.com/sitemap.xml
7. Click “Submit Sitemap.”
Submit your sitemap and you’re all set. Depending on how much page authority you have already accumulated on Google, it might take some time to see the status of your submitted sitemap. Give it time — Google will eventually accept it.
What If I Want to Add Webpages Later?
Once you define and submit your sitemap the first time, chances are you’ll want to tweak and add pages to your website every so often — and that’s completely fine. But keep in mind that if your website isn’t built on a platform that automatically generates a new sitemap and updates it on your web server when new pages are added, then every time you add a page — any page — to your website, that page will be missing from the sitemap that search engines see.
Remember, Google and other search engines will pick up the sitemap organically as long as you’ve updated the sitemap.xml file on your web server. But if you want to try to index your content the fastest way possible, you could resubmit your sitemap after publishing a new page — and it’s possible that Google would pick it up more quickly.