Seitenreport Seitenreport
Sitemap in WordPress

Fix forwarding in the XML Sitemap in WordPress

The sitemap should specify the desired destination address. In WordPress, check for Core Sitemap or Plugin Sitemap.

Core Sitemap or Plugin Sitemap

Compare plugin sitemap and current permalink. An old sitemap cache should not point further to the previous address after the correction.

Using robots.txt and the delivered XML file, determine the active sitemap producer. WordPress Core and SEO plugins can select different content and taxonomies. Exclusions belong in this source and not in a downloaded XML copy.

How to fix the issue in WordPress

  1. Go to /wp-sitemap.xml if the core sitemap is used. With an SEO plugin, you determine its sitemap index via robots.txt instead. Check whether the affected content is published and contained in the selected content type or taxonomy.
  2. Replace redirecting sitemap entries with the final canonical address. Fix the provider's URL generation so the old address does not return on its next run.

Start with one affected page or template. Check its output before applying the correction to other pages.

Example of this specific finding

Illustrative control case: The sitemap calls /performance-alt/, which redirects to /performance/ permanently. The generator uses an outdated URL source.

follow-up audit in WordPress

Review a published paper, a draft and a relevant taxonomy. After a change, retrieve the sitemap index and the affected partial sitemap without logged in session.

Take the final desired address directly into the sitemap and test the regular rebuild. Appropriately pass forwarding for old calls.

How to verify that the fix worked

After normal regeneration, each corrected entry returns 200 directly. Check the URL's language, domain and trailing-slash format together.

Check a sitemap and its URLs: Check whether the published sitemap URLs are accessible and match the pages you want indexed.

Derogations and scope

Do not remove the working redirect, just so that the old sitemap URL returns 200.

Related: WordPress with classic or block theme. SEO plugins and page builders are different; there is no universal menu path for all installations.

Classify the general error

Definition, system-independent causes and further correction examples: The sitemap should specify the desired destination address

Configuration and test signal documentation

WordPress: Core Sitemaps

Google: Create and Review Sitemaps

Related Sitemap Errors in WordPress