Code to “noindex” Paginated Pages in WordPress

/* Noindex Paginated Pages */
add_action('wp_head', 'wpflt_header_function_condition_noindex_paginated');
function wpflt_header_function_condition_noindex_paginated(){
if ( is_paged() ) { ?>
<meta name="robots" content="noindex" />
<?php }
};

Example of Paginated URL: https://example.com/category/page/2

Should paginated pages be indexed? No!. This dilutes the Search Results. Instead of Disallowing Index for Paginated pages through robots.txt, simply use below the filter in your child theme’s functions.php