que es un sitemap

What Is a Sitemap: The Complete Guide for Your Website

Last reviewed: May 2026 Is Google missing pages on your website? A sitemap is the answer. It is a file that acts as a map of your site, telling search engines which pages exist, when they were last updated and how important each one is. At our SEO agency Barcelona we set up and optimise every client’s sitemap to guarantee flawless indexing. In this guide we explain what a sitemap is, the different types, how to create one for your website and how to submit it to Google to improve the way your content is indexed.

What you will learn in this guide

  • What a sitemap is: Definition and purpose
  • Types of sitemap: XML, HTML, image, video
  • How to create one: In WordPress, by hand and with tools
  • How to submit it to Google: Setting it up in Search Console
  • Best practice: What to include and what to leave out

Contents

What is a sitemap?

A sitemap is a file listing the URLs of a website along with extra information about each page. Its main job is to help search engines such as Google discover, crawl and index your content more efficiently.

Think of the sitemap as the index of a book: it tells the search engine which pages exist and where to find them, without having to follow link after link.

What information does a sitemap contain?

  • The URL of each page: The full address of every page on the site
  • Last modified date: When the content was updated
  • Change frequency: How often it usually changes (daily, weekly, monthly)
  • Priority: How important each page is relative to the rest of the site

A sitemap is especially useful for large sites, new sites with few external links, or pages that are poorly linked internally. It makes it easier for Google to find content that might otherwise go unnoticed.

Types of sitemap

There are different types of sitemap depending on the format and the kind of content they list:

XML sitemap

The most important one for SEO. It is a file in XML format designed specifically for search engine crawlers. This is the type of sitemap you submit to Google Search Console. Typical location: yourdomain.com/sitemap.xml

HTML sitemap

A web page, visible to visitors, that lists all the site’s links in an organised way. Useful for improving navigation and user experience, especially on large sites. It also helps search engines, though only as a secondary signal.

Image sitemap

An extension of the XML sitemap that includes information about the site’s images. It helps your images appear in Google Images. You can include images in the main sitemap or create a dedicated one.

Video sitemap

Similar to the image sitemap, but for video content. It includes details such as title, description, duration and thumbnail. Useful if video is an important part of your content strategy.

News sitemap

Specific to news sites that want to appear in Google News. It has special requirements and only includes content from the last 2 days.

Why do you need a sitemap?

Not every site needs a sitemap equally urgently, but as a rule it is good practice to have one:

Sites that DO need a sitemap

  • Large sites: With hundreds or thousands of pages, the sitemap makes sure Google finds them all
  • New sites: Without external backlinks, Google takes longer to discover pages
  • Isolated content: Pages with few internal links pointing to them
  • Media content: If you have lots of images or videos you want indexed
  • News sites: Content published frequently that needs fast indexing

Sites where it matters less (but still helps)

  • Small sites: Fewer than 100 pages, well linked internally
  • Good architecture: Where every page is a few clicks from the home page
  • Plenty of backlinks: Authoritative sites that Google crawls often

Even if your site is small, creating a sitemap has no downsides and potential benefits. It is a tiny investment that makes life easier for search engines.

que es un sitemap

The structure of an XML sitemap

An XML sitemap follows a specific structure that search engines can read. Here is a simplified example:

Basic structure

<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
  <url>
    <loc>https://yourdomain.com/page/</loc>
    <lastmod>2025-01-15</lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.8</priority>
  </url>
</urlset>

Main tags

  • <loc>: The page URL (required)
  • <lastmod>: Last modified date (recommended)
  • <changefreq>: Change frequency: always, hourly, daily, weekly, monthly, yearly, never (optional)
  • <priority>: Priority from 0.0 to 1.0 (optional, and largely ignored by Google)

Technical limits

  • A maximum of 50,000 URLs per sitemap
  • A maximum size of 50 MB uncompressed
  • If you go over these limits, use a sitemap index pointing to several sitemaps

How to create a sitemap in WordPress

If you use WordPress, creating a sitemap is very simple thanks to SEO plugins:

With Yoast SEO

  1. Install and activate Yoast SEO
  2. Go to Yoast SEO → Settings → Site features
  3. Make sure “XML sitemaps” is switched on
  4. Your sitemap will be at: yourdomain.com/sitemap_index.xml

With Rank Math

  1. Install and activate Rank Math
  2. Go to Rank Math → Sitemap Settings
  3. Choose which content types to include
  4. Your sitemap will be at: yourdomain.com/sitemap_index.xml

With All in One SEO

  1. Install and activate AIOSEO
  2. Go to All in One SEO → Sitemaps
  3. Enable the sitemap and set the options
  4. Your sitemap will be at: yourdomain.com/sitemap.xml

These plugins keep the sitemap updated automatically whenever you publish or edit content. There is nothing else to do.

How to create a sitemap without WordPress

If you do not use WordPress, or you want more control, there are other ways to create a sitemap:

Online generators

Tools such as XML-Sitemaps.com, Screaming Frog or Sitemap Generator crawl your site and produce the XML file automatically. Useful for static sites or when you need a one-off sitemap.

Creating it by hand

For small sites you can write the XML file yourself following the structure above. Save it as sitemap.xml and upload it to the root of your domain.

Generating it in code

If your site is custom built, you can program the sitemap to be generated automatically. Most frameworks and CMSs have libraries or modules for this.

With Screaming Frog

  1. Download Screaming Frog SEO Spider (the free version covers up to 500 URLs)
  2. Enter your domain and run a crawl
  3. Go to Sitemaps → Create XML Sitemap
  4. Set the options and export the file
  5. Upload the file to the root of your domain

How to submit your sitemap to Google Search Console

The sitemap is a basic but fundamental part of technical SEO. It will not rank you on its own, but it makes it far easier for Google to discover and index all your important content.

At JRC Web we make sure every technical aspect of your website is set up correctly, including sitemaps, robots.txt, URL structure and information architecture.

As an SEO agency in Barcelona, we run full SEO audits covering all of these technical elements to make sure your site is optimised for search engines.

Not sure about the technical SEO of your website? Get in touch and we will review your case with no commitment.

What to include and exclude from the sitemap

Once the sitemap is created, you need to submit it to Google Search Console so Google knows about it:

Step by step

  1. Open Google Search Console (search.google.com/search-console)
  2. Select your property (domain)
  3. In the side menu, go to “Sitemaps”
  4. Under “Add a new sitemap”, enter your sitemap URL (e.g. sitemap.xml)
  5. Click “Submit”

Checking the status

Once submitted, Search Console will show you:

  • Status: Success, Has errors, or Couldn’t fetch
  • Discovered URLs: How many URLs Google found in the sitemap
  • Last read: When Google last read the sitemap

If there are errors, Search Console will tell you what they are so you can fix them.

In robots.txt too

Add the sitemap reference to your robots.txt file:
Sitemap: https://yourdomain.com/sitemap.xml

Common sitemap problems

Not every URL on your site belongs in the sitemap. Including unnecessary pages can dilute the importance of the content that matters.

What to include

  • Main pages (home, services, products)
  • Blog articles
  • Important category pages
  • Landing pages you want to rank
  • Pages with unique, valuable content

What NOT to include

  • Pages with noindex (it contradicts the instruction)
  • URLs with tracking parameters or filters
  • Login, basket and checkout pages
  • Thank you pages
  • Author archives if they add nothing
  • Deep pagination pages
  • Duplicate or low-quality content

Rule of thumb

If you do not want a page to appear in Google, keep it out of the sitemap. The sitemap should only contain URLs you want indexed and ranking.

Sitemaps and technical SEO

Having a sitemap does not guarantee Google will index every URL. These are the most frequent problems:

1. The sitemap is not reachable

Check that the sitemap URL works in a browser. Make sure it is not blocked by robots.txt or by server rules.

2. URLs returning errors

If the sitemap includes URLs returning 404 or 500 errors, Google will flag it as a problem. Review it and remove broken URLs.

3. Blocked URLs

Including URLs with noindex or blocked by robots.txt creates inconsistencies. Google will warn you in Search Console.

4. An out-of-date sitemap

If the sitemap is not updated automatically it can contain obsolete URLs or miss new pages. Use a plugin that keeps it current.

5. Too many low-quality URLs

Including thousands of low-value pages (tags, author archives, pagination) can affect how Google prioritises crawling your important content.

Sitemap best practice

The sitemap is one piece of the technical SEO puzzle. It works best combined with other good practices:

How it relates to robots.txt

Robots.txt controls what Google can crawl; the sitemap says what you want crawled. The two must be consistent: do not block in robots.txt what you list in the sitemap.

How it relates to indexing

The sitemap makes URLs easier to discover, but the decision to index depends on other factors: content quality, noindex tags, canonicals and so on.

How it relates to site architecture

Good internal linking reduces your dependence on the sitemap. If all your pages are well linked, Google will find them anyway. The sitemap is extra insurance.

How it relates to Core Web Vitals

The sitemap does not affect performance directly, but good Core Web Vitals improve how Google rates the pages it discovers through it.

Frequently asked questions about sitemaps

It is not compulsory, but it is highly advisable. Google can discover your pages through links, but a sitemap makes the process easier and faster. For large or brand-new sites, or ones with orphaned content, it is practically essential.
If you use an SEO plugin such as Yoast or Rank Math, the sitemap updates automatically every time you publish or edit content. There is nothing to do manually. If you built it by hand, you will need to update it whenever you add new pages.
The most common place is the root of the domain: tudominio.com/sitemap.xml. It can sit anywhere, though, as long as you point to it correctly in Search Console and robots.txt.
Not directly. A sitemap helps Google find and index your pages, but rankings depend on other factors: content quality, backlinks, user experience and so on. The sitemap is a technical requirement, not a ranking factor.
Google Search Console will flag the errors. The most common are URLs that return a 404, URLs blocked by robots.txt and URLs carrying a noindex tag. You need to fix them so Google can process the sitemap properly.

Click to rate this post!

How useful did you find this content?

Click a star to rate it!

Average rating!0/ 5. Vote count0

No votes yet! Be the first to rate this post.

More News