Custom post types are now included in the XML sitemap by default, and sitemap URLs work for post type names containing a hyphen or underscore.
Sitemap
- Custom post types included by default - every public post type is now listed in the sitemap, the way Yoast and WordPress core both do it. Previously only Posts and Pages were ever included, so products, plans, galleries and any other custom type were invisible to search engines through the sitemap. They appear automatically on update, with no configuration.
- Per-type control - each custom post type has its own checkbox under Settings, Sitemap. Types are included unless you switch them off, so a post type added by a plugin you install later is covered without revisiting the screen.
- Hyphenated and underscored type names fixed - sitemap URLs for a type such as house-plan or project-gallery returned 404 because the address only recognised letters. Those URLs now resolve, including their paged forms.
- Switched-off types are no longer reachable - a post type you have turned off, or one that is not public, now returns 404 at its sitemap address instead of still being served to anyone who guessed the URL.