Include custom post type single template, but respect theme override of template if it exists
You can use locate_template() first. If this returns anything but an empty string ” then the template exists either in parent or child theme. if( ” === locate_template( ‘custom-single.php’ ) ) { // Replace given template with your template path. }