The Moz Q&A Forum

    • Forum
    • Questions
    • My Q&A
    • Users
    • Ask the Community

    Welcome to the Q&A Forum

    Browse the forum for helpful insights and fresh discussions about all things SEO.

    1. SEO and Digital Marketing Q&A Forum
    2. Categories
    3. On-Page / Site Optimization
    4. Robots.txt: excluding URL

    Robots.txt: excluding URL

    On-Page / Site Optimization
    2 2 821
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as question
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • anakyn
      anakyn last edited by

      Hi,

      spiders crawl some dynamic urls in my website (example: http://www.keihome.it/elettrodomestici/cappe/cappa-vision-con-tv-falmec/714/ + http://www.keihome.it/elettrodomestici/cappe/cappa-vision-con-tv-falmec/714/open=true) as different pages, resulting duplicate content of course.

      What is syntax for disallow these kind of urls in robots.txt?

      Thanks so much

      1 Reply Last reply Reply Quote 0
      • john4math
        john4math last edited by

        You don't want to do this in robots.txt.  If you serve pages with these parameters, people will inevitably link to them, and even if they're disallowed in your robots.txt file, Google maybe still index them, according to this: "While Google won't crawl or index the content of pages blocked by robots.txt, we may still index the URLs if we find them on other pages on the web."

        This is what the rel=canonical tag is designed for.  You should use that to tell Google the page is duplicate content of another page on your site, and that it should refer to that other page.  You can read (and watch a video) about that here.

        1 Reply Last reply Reply Quote 1
        • 1 / 1
        • First post
          Last post
        • Correct robots.txt for WordPress
          jasongmcmahon
          jasongmcmahon
          1
          5
          180

        • Robots.txt Question for E-Commerce Sites
          Joe.Robison
          Joe.Robison
          0
          2
          450

        • Two Robots.txt files
          TrulyTravel
          TrulyTravel
          0
          5
          514

        • Should I be disallowing my forum in the robots.txt file?
          waleedkhalid
          waleedkhalid
          0
          5
          287

        • How to exclude URL filter searches in robots.txt
          Everett
          Everett
          0
          9
          8.6k

        • Is it possible to have the crawler exclude urls with specific arguments?
          Nobody1560986989723
          Nobody1560986989723
          0
          2
          392

        • Disallow a spammed sub-page from robots.txt
          zigojacko
          zigojacko
          0
          3
          475

        • Photogallery and Robots.txt
          Rapturecamps
          Rapturecamps
          0
          5
          831

        Get started with Moz Pro!

        Unlock the power of advanced SEO tools and data-driven insights.

        Start my free trial
        Products
        • Moz Pro
        • Moz Local
        • Moz API
        • Moz Data
        • STAT
        • Product Updates
        Moz Solutions
        • SMB Solutions
        • Agency Solutions
        • Enterprise Solutions
        • Digital Marketers
        Free SEO Tools
        • Domain Authority Checker
        • Link Explorer
        • Keyword Explorer
        • Competitive Research
        • Brand Authority Checker
        • Local Citation Checker
        • MozBar Extension
        • MozCast
        Resources
        • Blog
        • SEO Learning Center
        • Help Hub
        • Beginner's Guide to SEO
        • How-to Guides
        • Moz Academy
        • API Docs
        About Moz
        • About
        • Team
        • Careers
        • Contact
        Why Moz
        • Case Studies
        • Testimonials
        Get Involved
        • Become an Affiliate
        • MozCon
        • Webinars
        • Practical Marketer Series
        • MozPod
        Connect with us

        Contact the Help team

        Join our newsletter
        Moz logo
        © 2021 - 2026 SEOMoz, Inc., a Ziff Davis company. All rights reserved. Moz is a registered trademark of SEOMoz, Inc.
        • Accessibility
        • Terms of Use
        • Privacy