How to Build a Sitemap Using WordPress Plugins

The three main plugins, the settings that matter, and the configuration mistakes that quietly break sitemaps.

Victor Ijomah
By
Victor Ijomah
Victor Ijomah
Technical SEO Specialist
Victor Afamefuna Ijomah is a UK-based Technical SEO Specialist focused on how Google and AI engines like ChatGPT, Perplexity, and AI Overviews decide what gets discovered,...
- Technical SEO Specialist
Highlights
  • Every sitemap plugin lets you configure the same five things: content types, taxonomies, individual URL exclusions, lastmod handling, and media sitemap separation.
  • Yoast, Rank Math, and All in One SEO all do similar work, with the differences mostly being where each plugin hides its settings.
  • Yoast and Rank Math both produce their sitemap at /sitemap_index.xml, while All in One SEO uses /sitemap.xml, which matters when switching between plugins.
  • Yoast Premium's Crawl optimisation toggles can silently block AI crawlers and undo any AI Search positioning if they get left enabled.
  • The most common configuration mistake is leaving thin tag archives enabled in the sitemap, which dilutes the signal with hundreds of low-value URLs.

Part of the SiteMap Series

You picked the plugin route from Lesson 3: Choosing How to Build a Website Sitemap. Maybe Yoast came pre-installed, and you are sticking with it. Maybe you researched and chose Rank Math. Maybe All in One SEO has been on the site for years. Whichever plugin you have, the next move is to actually configure it to produce a clean sitemap.

The good news is that the three main WordPress sitemap plugins, Yoast SEO, Rank Math, and All in One SEO, all do the same fundamental work. They watch your content, generate the sitemap on the fly, and let you decide what gets included. Once you understand the universal configuration choices, switching between plugins is mostly about finding where each one hides its settings.

This lesson covers the principles that apply across all sitemap plugins, walks through the specific configuration paths for the three main options, flags the Yoast Premium setting that quietly blocks AI crawlers, and names the common mistakes that produce broken sitemaps even with a good plugin in place.

What every sitemap plugin lets you configure

Before you open a settings page, understand what you are actually choosing. Every reputable SEO plugin gives you control over five things, and these are the choices that determine whether your sitemap is clean or junk-filled.

  1. The first choice is which content types to include. WordPress ships with posts and pages, but most modern sites use custom post types too: products, courses, case studies, and portfolio items. Your plugin needs to know which of these to include in the sitemap. The default is usually to include posts and pages but exclude custom post types unless you tell it otherwise.
  2. The second choice is which taxonomies to include. Categories, tags, custom taxonomies. These create archive pages, and whether each archive belongs in your sitemap depends on whether it has meaningful content. A category page with five well-organised posts is worth including. A tag page with one post each across hundreds of tags is junk, and we covered why in Lesson 2: What’s Actually In Your Sitemap.
  3. The third choice is which individual URLs to exclude. Some pages need to stay out of the sitemap regardless of their content type: thank-you pages after form submissions, internal landing pages, and gated content. Plugins handle this either through per-page checkboxes on the post editor or through bulk exclusion settings.
  4. The fourth choice is how lastmod is calculated. Most plugins pull lastmod from the actual page modification date by default, which is what you want. Some plugins offer settings to override this, and overriding it usually produces worse sitemaps than the default.
  5. The fifth choice is whether to enable separate sitemap files for media. Image sitemaps and video sitemaps are different files, with their own elements and rules. Most sites do not need them as separate files because images and videos referenced on pages get picked up through the main sitemap.

These five choices are the same regardless of which plugin you use. The differences are in where each plugin hides them.

Sitemap settings in Yoast, Rank Math, and All in One SEO

The three main WordPress SEO plugins, in rough order of how often they appear on sites I audit.

1. Yoast SEO

Yoast SEO generates the sitemap at /sitemap_index.xml by default, with child sitemaps for each enabled content type (/post-sitemap.xml, /page-sitemap.xml, and so on). The settings to control all of this live in Yoast SEO → Settings.

To control content type inclusion, navigate to Content types in the Yoast settings. Each post type has a toggle for whether it appears in search results, and disabling that toggle removes it from the sitemap. Pages and posts are on by default; custom post types follow your earlier configuration.

To control taxonomy inclusion, the path is Categories & tags in the same settings menu. Categories are included by default, tags are usually included too, and custom taxonomies you have created appear here for individual control.

For individual URL exclusion, Yoast uses the per-page Advanced section on each post or page editor. Setting Allow search engines to show this post in search results to No noindexes the page and removes it from the sitemap.

One Yoast Premium setting worth knowing about: the Crawl optimisation page includes toggles that block AI crawlers from your site. Specifically, you will find options to disallow Google-Extended (Google’s training crawler for Gemini), GPTBot (OpenAI’s crawler for ChatGPT), and CCBot (Common Crawl, used by Claude, Perplexity, and others). If you are positioning your content for the AI Search era, these need to stay off. The whole point of having a sitemap in this era is that AI crawlers can find and use your content. Leaving these toggles enabled undoes the positioning silently.

2. Rank Math

Rank Math generates its sitemap at /sitemap_index.xml, the same path Yoast uses. This is a quiet convenience: switching between the two plugins does not require a robots.txt update or a Search Console resubmission. The settings live in Rank Math → Sitemap Settings.

The interface is broken into tabs. The General tab has master toggles for whether the sitemap is active at all and the maximum URLs per file. The Posts, Pages, and Categories/Tags tabs each control inclusion for that content type, with toggles for whether to include them, how many to show per page, and which images to attach.

Rank Math has one advantage over Yoast for many users: each content type’s settings page also lets you select specific posts or pages to exclude without having to edit each one individually. If you have a list of URLs you want kept out of the sitemap, this is faster than the Yoast per-page approach.

For lastmod handling, Rank Math also defaults to using the actual modification date.

3. All in One SEO

All in One SEO (often shortened to AIOSEO) generates the sitemap at /sitemap.xml by default, which differs from Yoast and Rank Math. If you switch to AIOSEO from one of the other plugins, the sitemap URL changes, and you will need to update robots.txt and resubmit to Search Console.

The settings live in All in One SEO → Sitemaps. The interface is organised into General, XML Sitemap, Video Sitemap, News Sitemap, and HTML Sitemap tabs.

The XML Sitemap tab is where the work happens. Post types controls which content types are included. Taxonomies controls categories, tags, and custom taxonomies. Advanced settings lets you set the URL limit per sitemap file (defaults to 1000, which is fine for most sites) and exclude specific URLs by pattern.

AIOSEO uses the actual page modification date for lastmod by default, the same as the others.

A note on the HTML sitemap tab: AIOSEO can also generate a user-facing HTML sitemap for your site, which is a different artefact entirely (covered back in Lesson 3 of Module One: XML Sitemap vs HTML Sitemap). Whether you enable that is a separate question from whether your XML sitemap is set up properly.

Common configuration mistakes

Even with a good plugin in place, the same configuration mistakes show up repeatedly across the sites I audit. These are the ones worth checking after you have set everything up.

1. Leaving thin taxonomies enabled is the most common mistake.

Tags in particular tend to be enabled by default, and most blogs have hundreds of tags with one or two posts each. Those tag archive pages get included in the sitemap, and they dilute the signal. If your tags do not have meaningful content under them, disable tag archives in the sitemap settings.

2. Forgetting to enable custom post types is the second most common.

If you spent months building a course catalogue or a case study library and the sitemap is not including them, search engines and AI crawlers have a much harder time finding that content. Check that every custom post type you publish is enabled in the plugin’s sitemap settings.

3. Confusion between noindex and sitemap exclusion is the third.

Setting a page to noindex usually removes it from the sitemap (the plugin assumes you do not want noindexed content in there), but the behaviour varies by plugin and version. If you want a page in the sitemap but with noindex set, or vice versa, check the plugin’s specific behaviour rather than assuming.

4. Treating media sitemaps as automatic is the fourth.

Image and video sitemaps are different files, and most plugins generate them separately if you enable them. If you have a media-heavy site and want images discoverable in image search, check whether the image sitemap is enabled in your plugin’s settings.

Where this leaves us

You should now have a properly configured plugin producing a clean sitemap. Whichever of the three plugins you went with, the principles are the same: content types you want indexed, taxonomies that have meaningful content, excluded URLs that should not be advertised, lastmod values pulled honestly from page modification dates.

If you are on WordPress, the plugin route covers most situations. But not every site is a WordPress site, and not every site owner wants a plugin handling their sitemap. The next lesson covers the manual XML approach, for static sites, headless CMSes, custom-coded sites, and the rare WordPress site where the plugin route simply does not fit.

Up next: Building a Sitemap Manually with XML →


This is Module 2: Lesson 4 of The Sitemap Series, a Technical SEO series on sitemaps from first principles, built for the AI Search era.

Share This Article
Victor Ijomah
Technical SEO Specialist
Follow:
Victor Afamefuna Ijomah is a UK-based Technical SEO Specialist focused on how Google and AI engines like ChatGPT, Perplexity, and AI Overviews decide what gets discovered, understood, and cited. He holds an M.Sc in Digital Marketing from the University of Chester and is the editor of The Technical SEO Library, a publication on crawl systems, schema, entity SEO, AI crawler management, and the technical foundations of visibility in the AI Search era.
Leave a Comment