How to Stop creating PAGE Default sitemap in WordPress

Page Sitemap

Hey You want to stop automatic creating sitemap for pages, so paste given code in your wordpress website’s theme’s functions.php.

How to Stop Sitemap for PAGE

  1. open active theme’s folder.
  2. paste given code in functions.php.
  3. then click SAVE button.

Code – 

add_filter(
'wp_sitemaps_post_types',
function( $post_types ) {
unset( $post_types['page'] );
return $post_types;
}
);