- How to Fix WWW and Non-WWW Version Redirects to Improve Your SEO
- How to Fix: No H1 Heading Found on Your Homepage
- How to Fix Missing H2 Headings on Your Homepage
- Re-run Checks Button in SureRank
- Fix Critical Error: Another SEO Plugin Detected in SureRank
- Fix Warning: Site Tagline Is Not Set in SureRank
- How to Fix Multiple SEO Plugins Detected on Your Site
- How to Fix: Homepage is Not Indexable by Search Engines
- Warning: Homepage Does Not Contain Internal Links
- How to Fix Missing Alt Text on Homepage Images
- How to Fix: Search Engine Title is Missing on the Page
- Page Level SEO: Broken Links Detected
- How to Fix Missing Alt Text on Images
- How to Fix Page URLs That Are Too Long
- Page Level SEO Warning: No Links Found on This Page
- Page Level SEO Warning: No Images or Videos Found
- Page Level SEO Warning: Missing Search Engine Description
- Page Level SEO Warning: No Subheadings Found on This Page
- Page Level SEO Warning: Canonical Tag is Missing
- Page Level SEO Warning: Open Graph Tags Missing
- Customize Final Title Tag surerank_final_title
- Customize Post Type Archive Title Output surerank_post_type_archive_title
- Customize Archive Page Title with surerank_archive_title
- CustomizeModify the Search Results Page Title surerank_search_title
- Customizing the 404 Page Title surerank_not_found_title
- Customizing the Title Separator surerank_title_separator
- How to Remove Archive Prefixes from Titles Using SureRank
- Customize Homepage Pagination Format surerank_homepage_pagination_format
- Customize Maximum SEO Title Length surerank_title_length
- Enable/Disable Pagination in SureRank Archives surerank_show_pagination
- Show or Hide Site Name in SEO Title surerank_show_site_name
- Customize Robots Meta Tags surerank_robots_meta_array
- Add “noindex” to Paginated Pages surerank_noindex_paginated_pages
- Customize Meta Description Length surerank_description_length
- Customize Product Category Rewrite Rules surerank_product_category_rewrite_rules
- Remove Product Category Base surerank_remove_product_category_base
- Customize Category URL Structure surerank_remove_category_base
- Disable Permalinks in RSS Feeds surerank_disable_permalink_in_feed
- Customize Maximum URL Slug Length surerank_url_length
- Disable Feed Indexing in SureRank surerank_disable_feed_indexing
Customize Robots Meta Tags surerank_robots_meta_array
Hook: surerank_robots_meta_array
Description: Use the surerank_robots_meta_array filter to customize the output of the <meta name="robots"> tag on your site. This allows you to dynamically control search engine behavior by adding, modifying, or removing directives like noindex, nofollow, noarchive, and more. This hook is especially useful when you want to fine-tune the visibility of specific pages or sections for SEO purposes.
Source: inc/frontend/robots.php
Usage: Modify the array of robots directives before they are rendered in the HTML <head> section.
Example:
// Add 'nofollow' to the robots meta tag using the SureRank filter
add_filter( 'surerank_robots_meta_array', 'custom_robots' );
function custom_robots( $robots ) {
$robots[] = 'nofollow';
return $robots;
}You can add the example code to your child theme’s functions.php file or use a plugin like Code Snippets to safely insert custom code. Using a code snippet plugin is recommended for easier management and to ensure the code remains active even if you switch themes.
We don't respond to the article feedback, we use it to improve our support content.