Disable Featured Image from Pages

If you want to disable featured images from appearing on the front end of pages, you can use this PHP Snippet:

/**
 * Disable Featured image on all post types.
 */
function your_prefix_featured_image() {
 $post_types = array('page');

 // bail early if the current post type if not the one we want to customize.
 if ( ! in_array( get_post_type(), $post_types ) ) {
 return;
 }
 
 // Disable featured image.
 add_filter( 'astra_featured_image_enabled', '__return_false' );
}

add_action( 'wp', 'your_prefix_featured_image' );

Related Article: How to add PHP Snippets

Not the solution you are looking for? Check other articles, or open a support ticket.