• Resolved masouddarvishi1992

    (@masouddarvishi1992)


    Hello. Is it necessary to block add to cart links via robots.txt? For example, with this method:

    Disallow: /?add-to-cart=

    Does it have a positive effect on SEO?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Support Rank Math Support

    (@rankmathsupport)

    Hello @masouddarvishi1992,

    Thank you for contacting Rank Math support.

    Yes, you can use the robots.txt file to prevent Google from crawling add-to-cart URLs. It will help you save the crawl budget, and Google will be able to spend it on the URLs that you want to be indexed in the SERPs.

    You should use the following rule:

    Disallow: *?add-to-cart=*

    Hope that helps, and please do not hesitate to let us know if you need our assistance with anything else.

    Thread Starter masouddarvishi1992

    (@masouddarvishi1992)

    @rankmathsupport

    Is this necessary? I noticed, these ?add-to-cart works correctly and sometimes get 301 redirect.
    No 404 error is thrown. Why should it be bad for the crawl budget?

    If it’s bad, why doesn’t rankmath do it?

    Because of this, I get the following error in the search console:

    Indexed, though blocked by robots.txt

    This is a non-critical issue. Pages with these issues are indexed, but their search result appearance can be improved.

    Plugin Support Rank Math Support

    (@rankmathsupport)

    Hello @masouddarvishi1992,

    We didn’t say it’s bad for crawling but blocking those URLs will ease up the crawling budget.

    In most cases, having those URLs indexed will cause duplicate content since the primary page (the product link without the ?add-to-cart= query) is already indexed. However, if you believe those links contribute benefits to your website’s overall SEO performance, then it is fine to let Google crawl them, otherwise, you can safely ignore the “Indexed, though blocked by robots.txt” warning on your GSC.

    Hope that clarifies any doubts.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Add to cart Links WooCommerce’ is closed to new replies.