Hello,
Thank you for contacting the support, and sorry for any inconvenience that might have been caused due to that.
You can simply prevent Google from indexing these URL parameters by excluding them in your robots.txt file.
Please add this configuration to your robots.txt:
Disallow: /*?modal=*
That should resolve your issue. We are looking forward to helping you.
Thanks Jeremy,
So do i add that inside wp-admin using Rank Math……. or do I manually add it to the file directly?
Hello,
Since Rank Math manage the robots.txt file virtually, you will need to edit the file by heading over to WP Dashboard > Rank Math > General Settings > Edit robots.txt
Hope that helps and please do not hesitate to let us know if you need our assistance with anything else.
Ok great.
So I googled a bit and have amended your code to this….
Disallow: /*?*
My expectation is that this will stop Google from indexing ANY URLs with ANY parameters.
I have added exactly that code here…
WP Dashboard > Rank Math > General Settings > Edit robots.txt
Am i doing it all right?
Hello,
Yes, that disallow statement would tell the bots not to crawl any URLs with parameters.
You may double-check if the statement is updated by visiting the robots.txt file using the URL your-domain.com/robots.txt (please replace “your-domain.com” with your actual domain).
If the file is updated properly, then everything would be fine from your end.
Hope that helps.
Thank you.
Yes that helps, thank you all very very much. Great support.
Hello,
We are super happy that we could address your concern. If you have any other questions in the future, know that we are here to help you.
If you don’t mind us asking, could you please leave us a review (if you haven’t already) on https://wordpress.org/support/plugin/seo-by-rank-math/reviews/#new-post about your overall experience with Rank Math? We appreciate your time and patience.
If you have another question in the future, please feel free to create a new forum topic, and it will be our pleasure to assist you again.
Thank you.