Problem with indexing of url with parameters.

#993352
Viewing 5 replies - 1 through 5 (of 5 total)
  • Hello,

    We apologize for the issue you are facing with the indexing of URLs with parameters. It can be quite challenging to manage how Google indexes these types of URLs, especially when they can clutter your site’s index and affect your crawl budget.

    Here are some steps you can take to address this issue:

    1. Use Canonical Tags

    Ensure that you are using canonical tags correctly on your pages. The canonical tag should point to the main version of the page without parameters. This tells Google which version of the page to index. For example, for the URL `https://rankmath.com/wp-content/uploads/2022/09/Manual-Action.png the canonical tag should be:

    This way, Google understands that the version without parameters is the preferred one.

    2. Implement URL Parameters in Google Search Console

    You can specify how Google should handle URL parameters in Google Search Console. This feature allows you to tell Google which parameters to ignore when crawling your site. Here’s how to do it:

    • Go to Google Search Console.
    • Select your property.
    • Navigate to Legacy tools and reports > URL Parameters.
    • Add the parameters you want Google to ignore and specify how they affect content.

    3. Use Robots.txt

    While you mentioned that disallowing them in your robots.txt file did not yield the desired results, it’s still worth ensuring that your robots.txt file is correctly configured. You can disallow specific parameters like this:

    User-agent: *
    Disallow: /*?*

    This will prevent search engines from crawling any URL with a question mark (indicating parameters).

    4. Remove URLs from Google Index

    If there are already indexed URLs that you want to remove, you can use the Remove URLs tool in Google Search Console:

    • Go to Google Search Console.
    • Select your property.
    • Navigate to Removals under the Index section.
    • Click on New Request and enter the URLs you want to remove.

    5. Monitor Your Sitemap

    Make sure your sitemap only includes the canonical versions of your pages without parameters. This helps guide Google on which pages to crawl and index.

    6. Content Quality and Site Audit

    Conduct a content audit to ensure that all indexed pages provide value. If there are low-quality pages or duplicates, consider removing them or adding noindex tags where appropriate.

    By following these steps, you should be able to manage how Google indexes your URLs with parameters more effectively. If you continue to experience issues, please reply to this ticket with any additional details or questions, and a human agent from our support team will assist you further.

    Thank you for raising this concern!

    Sources:
    Why Did My Website Disappear From Google Search? » Rank Math
    Why Did My Website Disappear From Google Search? » Rank Math
    How to Fix Submitted URL Marked ‘NoIndex’ Error » Rank Math

    Html Aps
    Rank Math free

    1. You’ll see in the links provided that the right canonical tags have been setup.

    2. I don’t think this option is available anymore. I can’t find it.

    3. I did try robots.txt but it didn’t fix the problem it made it worse, as described in the original post.

    4. It’s impossible to remove 300k+ url manually. Is there another way to do it?

    5. Our sitemap is generate by Rank Math and looks good.

    6. I don’t think this applies here, as they are still seen by GSC.

    Hello,

    From the URLs you shared, these are the filter added to your URLs:

    ?add-to-cart=
    ?source=
    ?srsltid=
    ?rating_filter=
    ?filter_hoejde=
    ?filter_socket=
    ?filter_diameter=
    ?filter_typefilter=

    In this case, you may use this code/filter on your site to set them to noindex:

    add_filter( 'rank_math/frontend/robots', function( $robots ) {
    	$url = home_url( $_SERVER['REQUEST_URI'] );
    	if (strpos($url,'?add-to-cart=') !== false || strpos($url,'?source=') || strpos($url,'?srsltid=') || strpos($url,'?rating_filter=') || strpos($url,'?filter_hoejde=') || strpos($url,'?filter_socket=') || strpos($url,'?filter_diameter=') || strpos($url,'?filter_typefilter=')) {
                    $robots['index'] = 'noindex';
                    $robots['follow'] = 'nofollow';
    	        return $robots;
            }
    	return $robots;
    });

    And here’s a guide you can follow to apply that:
    https://rankmath.com/kb/wordpress-hooks-actions-filters/

    Also, you should not include a disallow rule in your robots.txt for those filter paths so Google can read the noindex meta tag.

    Looking forward to helping you.

    Html Aps
    Rank Math free

    Thank you very much for the answer.

    Hello,

    You’re welcome.

    We are super happy that we have addressed your concern. If you have any other questions in the future, know that we are here to help you.

    If it isn’t too much to ask for – would you mind leaving us a review here?
    https://www.trustpilot.com/evaluate/www.rankmath.com
    https://wordpress.org/support/plugin/seo-by-rank-math/reviews/#new-post

    It only takes a few minutes but it makes a huge difference.

    It would mean so much to us and would go a really long way.

    Thank you.

Viewing 5 replies - 1 through 5 (of 5 total)

The ticket ‘Problem with indexing of url with parameters.’ is closed to new replies.