Back to Community

How to Remove or Customize Rank Math SEO Elements on Your WordPress Site

33 threads Sep 10, 2025 PluginRank math seo

Content

Many WordPress users leverage the powerful Rank Math SEO plugin to optimize their sites. However, a common need arises to customize its interface or output, such as removing comments from the page source, hiding SEO scores on specific pages, or disabling meta boxes for certain user roles or post types. This guide covers the most frequent requests and their solutions.

Why Would You Want to Remove These Elements?

There are several valid reasons for wanting to clean up Rank Math's output or backend interface:

  • Cleaner Code: Removing plugin credit comments and unnecessary inline CSS can lead to cleaner HTML source code.
  • Improved User Experience: Site administrators may want to simplify the WordPress admin for clients or other users by hiding complex SEO meta boxes and fields they don't need.
  • Performance: While minor, disabling unused features can slightly reduce page load times.
  • Custom Design: You may want to reposition or restyle certain elements, like breadcrumbs, to better fit your site's design.

Common Solutions for Customizing Rank Math

1. Removing the Plugin Credit Comment

The most common request is to remove the comment Rank Math adds to your page's HTML source:

<!-- Search Engine Optimization by Rank Math - https://rankmath.com/ -->

Solution: Add the following filter to your theme's functions.php file or a code snippets plugin:

add_filter( 'rank_math/frontend/remove_credit_notice', '__return_true' );

2. Hiding SEO Meta Boxes and User Profile Fields

To remove Rank Math SEO fields from user profile edit pages:

Solution via Settings: Navigate to Rank Math SEO → Titles & Meta → Authors. Ensure you are in Advanced Mode, then disable the "Add SEO Controls" option.

Solution via Code (for specific user meta fields): Use a filter to target specific social profile fields (e.g., Twitter, Facebook).

3. Disabling the SEO Score on Specific Pages/Posts

To hide the SEO score display, for example, on WooCommerce product pages:

add_filter( 'rank_math/show_score', function () {
    if ( is_product() ) { // Target WooCommerce product pages
        return false;
    }
} );

4. Removing Inline CSS (e.g., for TOC Block)

To dequeue the inline CSS added by the Table of Contents block:

add_action( 'wp_enqueue_scripts', function() {
    wp_dequeue_style( 'rank-math-toc-block-style' );
}, 9999 );

5. Controlling Breadcrumb Display

To prevent breadcrumbs from appearing on the homepage:

<?php
if ( function_exists( 'rank_math_the_breadcrumbs' ) && ! is_front_page() ) {
    rank_math_the_breadcrumbs();
}
?>

6. Disabling Features for Custom Post Types

Completely removing Rank Math's interface from a custom post type's admin screens requires multiple filters. This involves removing meta boxes, admin table columns, and other elements, which typically requires a more custom and comprehensive code solution.

Important Notes on Implementation

  • Where to Add Code: Always add custom code to your child theme's functions.php file or use a reputable code snippets plugin to avoid losing modifications after theme updates.
  • Clear Caches: After implementing these changes, clear any caching plugins or server-side caches to see the results immediately.
  • Plugin Updates: These filters are based on the plugin's API. The Rank Math team strives to keep them stable, but it's good practice to verify functionality after major plugin updates.

By using these targeted solutions, you can tailor the Rank Math SEO experience to fit your specific website needs, creating a cleaner environment for both visitors and content editors.

Related Support Threads Support