Technology

Wordpress brings Built-in XML Sitemaps for SEO

The recent beta release of WordPress 5.5 introduces built-in XML sitemaps for site visibility.

Sitemaps help crawlers to easily and better discover website content. Therefore, WordPress worked on the proposal for built-in functionality to generate XML sitemaps.

According to the the proposal: “Sitemaps help WordPress sites become more discover-able by providing search engines with a map of content that should be indexed.

This core sitemaps feature aims to provide the base required functionality for the Sitemaps protocol for core WordPress objects, then enables developers to extend this functionality with a robust and consistent set of filters. For example, developers can control which object types (posts, taxonomies, authors) or object sub-types (post types, taxonomies) are included, exclude specific entries, or extend sitemaps to add optional fields. See below for the full list.

Make Wordpress

How to enable built-in XML Sitemaps in WordPress?

XML Sitemaps will be enabled by default from Wordpress 5.5 and plus, making the following object types index-able: –

  • Homepage
  • Posts page
  • Core post types (i.e. pages and posts)
  • Custom post types
  • Core taxonomies (i.e. tags and categories)
  • Custom taxonomies
  • Author archives

By default, sitemaps are created for all public post types and taxonomies, as well as for author archives.

Additionally, the robots.txt file exposed by WordPress will reference the sitemap index.

Where the default WordPress XML Sitemap is located?

By default, the WordPress creates a sitemap index at /wp-sitemap.xml which includes sitemaps for all supported content, separated into groups by type. Each sitemap file contains a maximum of 2,000 URLs per sitemap, when that threshold is reached a new sitemap file is added.

How to disable built-in WordPress XML Sitemaps?

To disable built-in WordPress XML sitemaps for your website, follow any of the following method: –

  1. Discourage search engines to index your website from Wordpress Settings => General Screen. It’ll automatically disable XML Sitemaps and remove the reference from robots.txt file as well.
  2. Alternatively, use the wp_sitemaps_is_enabled filter, or add the line remove_action( 'init', 'wp_sitemaps_get_server' ); in functions.php of your theme to disable initialization of any sitemap functionality.

What to do with existing XML sitemaps generated by other plugins after this new feature?

Many sites already have a plugin active that implements sitemaps. For most of them, that will no longer be necessary, as the feature in WordPress core suffices. However, there is no harm in keeping them. The core sitemaps feature was built in a robust and easily extensible way. If for some reason two sitemaps are exposed on a website (one by core, one by a plugin), this does not result in any negative consequences for the site’s discover-ability.

Leave a Reply

Back to top button

Oh No! Why did you do this to us?

We've detected an ad or JS blocker in your browser. Please disable it to continue browsing Telefeeds website. Allowing ads from Telefeeds will help its team, author, and editors to deliver more valuable and authentic news to you. If you want to these ads permanently blocked and still want to read our news then, we request you to contribute with donation to Telefeeds team as a kind act. Keep growing mutually.