Hello,
We apologize for the issue you are facing with spam content appearing in Google search results for your site. It sounds like you’ve taken several important steps to clean up your site and optimize it with Rank Math, which is great.
The links you are seeing in the search results, formatted like `https://support.rankmath.com suggest that your site may be experiencing internal site search spam. This type of spam can occur if your internal search feature is not properly configured, allowing spammers to create indexed pages that can harm your site’s SEO.
To address this issue, we recommend the following steps:
-
Noindex Search Results: Ensure that you have set your search results pages to "noindex" so that they are not indexed by search engines. You can do this by navigating to Rank Math SEO → Titles & Meta → Misc Pages in your WordPress dashboard and enabling the Noindex Search Results option. Here’s a visual guide:

-
Check for Internal Links: Make sure that there are no internal links pointing to these spammy search result pages. If there are, remove them or update them to point to relevant content instead.
-
Submit a Reconsideration Request: If you believe your site has been penalized due to these spam links, consider submitting a reconsideration request through Google Search Console after ensuring that all spammy content has been removed and the noindex settings are applied.
-
Monitor Google Search Console: Keep an eye on the Google Search Console for any messages or manual actions that may indicate issues with your site.
-
Content Audit: Conduct a content audit to identify any other potential issues or low-quality pages that may be affecting your site’s reputation.
If you continue to see these spam links after implementing these changes, please reply to this ticket with any additional details or specific errors you might be encountering, and a human agent from our support team will assist you further.
Thank you for raising this concern, and we hope this guidance helps resolve the issue!
This is an automated reply from Rank Math Support Bot. Your ticket has been assigned to a human agent and we will get back to you shortly.
Hello,
I have updated the sensitive data as requested. Can you please check further?
Thank you.
Hello,
Thank you for your patience.
We have removed the public URLs in this ticket as requested.
In this case, you can add this filter to your site to noindex any URLs with ?sales=
and remove them on the search results page:
add_filter( 'rank_math/frontend/robots', function( $robots ) {
$url = home_url( $_SERVER['REQUEST_URI'] );
if( (strpos($url,'?sales=') !== false) ) {
$robots['index'] = 'noindex';
$robots['follow'] = 'nofollow';
}
return $robots;
});
Here’s a guide you can follow to apply that:
https://rankmath.com/kb/wordpress-hooks-actions-filters/
Also, we recommend running a security scan on your site and checking if there is malware that is causing the issue.
Here’s a great article on how to secure your WordPress website:
https://mythemeshop.com/blog/wordpress-security-tips/
Looking forward to helping you.
I’ve added that snippet now, thank you. I’ve cleaned malware already, too.
But checking google search console, I see another one URL being indexed: /?m=
Should I create an additional snippet or can I add that string to the original snippet?
Hello,
You can add it to the snippet like this and follow the pattern if there are more strings you want to include:
add_filter( 'rank_math/frontend/robots', function( $robots ) {
$url = home_url( $_SERVER['REQUEST_URI'] );
if( (strpos($url,'?sales=') !== false) || strpos($url,'?m=')) {
$robots['index'] = 'noindex';
$robots['follow'] = 'nofollow';
}
return $robots;
});
Looking forward to helping you.