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. Intermediate & Advanced SEO
    4. Robot.txt help

    Robot.txt help

    Intermediate & Advanced SEO
    23 4 203
    • 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.
    • Studio33
      Studio33 last edited by

      Hi,

      We have a blog that is killing our SEO.

      We need to

      Disallow

      Disallow: /Blog/?tag*
      Disallow: /Blog/?page*
      Disallow: /Blog/category/*
      Disallow: /Blog/author/*
      Disallow: /Blog/archive/*
      Disallow: /Blog/Account/.
      Disallow: /Blog/search*
      Disallow: /Blog/search.aspx
      Disallow: /Blog/error404.aspx
      Disallow: /Blog/archive*
      Disallow: /Blog/archive.aspx
      Disallow: /Blog/sitemap.axd
      Disallow: /Blog/post.aspx

      But Allow everything below /Blog/Post

      The disallow list seems to keep growing as we find issues. So rather than adding in to our Robot.txt all the areas to disallow.  Is there a way to easily just say Allow /Blog/Post and ignore the rest.  How do we do that in Robot.txt

      Thanks

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

        That would be something like this, please check this or test this within Google Webmaster Tools if it works because I don't want to screw up your whole site. What this does is disallowing your complete site and just allows the /Blog/Post urls.

        User-agent: *
        Disallow: /
        Allow: /Blog/Post

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

          Well, no point in a blog that hurts your seo 😉

          I respectfully disagree with Martijin; I believe what you would want to do is disallow the Blog directory itself, not the whole site. It would seem if you Disallow: / and _Allow:/Blog/Post _ that you are telling SEs not to index anything on your site except for /Blog/Post.

          I'd recommend:

          User-agent: *
          Disallow: /Blog/
          Allow: /Blog/Post

          This should block off the entire Blog directory except for your post subdirectory. As Maritijin stated; always test before you make real changes to your robots.txt.

          Martijn_Scheijbeler 1 Reply Last reply Reply Quote 0
          • Martijn_Scheijbeler
            Martijn_Scheijbeler @G2W last edited by

            There was a reason that I said he should test this!

            We're getting closer David, but after reading the question again I think we both miss an essential point ;-). As we know also exclude the robots from crawling the 'homepage' of the blog. If you have this homepage don't forget to also Allow it.

            G2W 1 Reply Last reply Reply Quote 0
            • G2W
              G2W @Martijn_Scheijbeler last edited by

              Correct, Martijin. Good catch!

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

                Thanks guys so I have

                User-agent: *
                Disallow: /Blog/
                Allow: /Blog/post
                Allow: /Blog/Post

                that works.  My Home page also works.  I there anything wrong with including both uppercase "Post" and lowercase "post".  It is lowercase on the site but want uppercase "P" just incase.  Is there a way to make the entry non case sensitive?

                Thanks

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

                  "We're getting closer David, but after reading the question again I think we both miss an essential point ;-)"  What was the essential point you missed.  sorry I don't understand.  I don;t want to make a mistake in my Robot.txt so would like to be 100% sure on what you are saying

                  G2W 1 Reply Last reply Reply Quote 0
                  • G2W
                    G2W @Studio33 last edited by

                    Well what Martijn (sorry, I spelled his name wrong before) and I were saying was not to forget to allow the landing page of your blog - otherwise this will not be indexed as you are disallowing the main blog directory.

                    Do you have a specific landing page for your blog or does it go straight into the /posts directory?

                    I'd say there's nothing wrong with allowing both Blog/Post and Blog/post just to be on the safe side...honestly not sure about case sensitivity in this instance.

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

                      The structure is:

                      www.mysite.com - want to see everything at this level and below it

                      www.mysite.com/Blog - want to BLOCK everything at this level

                      www.mysite.com/Blog/posts - want to see everything at this level and below it

                      G2W 1 Reply Last reply Reply Quote 0
                      • G2W
                        G2W @Studio33 last edited by

                        Yup, I understand that you want to see your main site. This is why I recommended blocking only /Blog and not / (your root domain).

                        However, many blogs have a landing page. Does yours? In other words, when you click on your blog link, does it take you straight to Blog/posts or is there another page in between, eg /Blog/welcome?

                        If it does not go straight into Blog/posts you would want to also allow the landing page.

                        Does that make sense?

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

                          Thanks it goes straight to www.mysite.com/Blog

                          G2W 1 Reply Last reply Reply Quote 0
                          • G2W
                            G2W @Studio33 last edited by

                            Ok then you should be all set if your tests on GWMT did not indicate any errors.

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

                              I'm wondering why you want to block crawling of these URLs - I think what you're going for is to not index them, yes? If you block them from being crawled, they'll remain in the index. I would suggest considering robots meta noindex tags - unless you can describe in a little more detail what the issue is?

                              -Dan

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

                                Hi Dan,

                                The issue is my blog had tagging switched on, it cause canonicalization mayhem.

                                I switched it off, but the tags still appears in Google Webmaster Tools (GWMT).  I Remove URL via GWMT but they are still appearing.  This has also caused me to plummet down the SERPs!  I am hoping this is why my SERPs had dropped anyway!  I am now trying to get to a point where google just sees my blog posts and not the ?Tag or ?Author or any other parameter that is going to cause me canoncilization pain.  In the meantime I am sat waiting for google to bring me back up the SERPs when things settle down but it has been 2 weeks now so maybe something else is up?

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

                                  Hi There

                                  Where are they appearing in WMT? In crawl errors?

                                  You can also control crawling of parameters within webmaster tools - but I am still not quite sure if you are trying to remove these from the index or just prevent crawling (and if preventing crawling, for what reason?) or both?

                                  -Dan

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

                                    Hi Dan,

                                    I am getting duplicate content errors in WMT like

                                    www.mysite.com/Blog/?tag=ABC

                                    www.mysite.com/Blog/?Page=1

                                    This is because tag=ABC and page=1 are both different ways to get to www.mysite.com/Blog/Post/My-Blog-Post.aspx

                                    To fix this I have remove the URL's www.mysite.com/Blog/?tag=ABC and www.mysite.com/Blog/?Page=1from GWMT and by setting robot.txt up like

                                    User-agent: *
                                    Disallow: /Blog/
                                    Allow: /Blog/post
                                    Allow: /Blog/Post

                                    I hope to solve the duplicate content issue to stop it happening again.

                                    Since doing this my SERP's have dropped massively.  Is what I have done wrong or bad?  How would I fix?

                                    Hope this makes sense thanks for you help on this its appreciated.

                                    Andrew

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

                                      Andrew

                                      I doubt that one thing made your rankings drop so much. Also, what type of CMS are you on? Duplicate content like that should be controlled through indexation for the most part, but I am not recognizing that type of URL structure as any particular CMS?

                                      Are just the title tags duplicate or the entire page content? Essentially, I would either change the content of the pages so they are not duplicate, or if that doesn't make sense I would just "noindex" them.

                                      -Dan

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

                                        Hi

                                        The blog is www.dotnetblogengine.com

                                        The content is only on the blog once it is just it can be accessed lots of different ways

                                        evolvingSEO 1 Reply Last reply Reply Quote 0
                                        • evolvingSEO
                                          evolvingSEO @Studio33 last edited by

                                          Hi There... that address does not seem to work for me. Should it be .net? http://www.dotnetblogengine.net/

                                          -Dan

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

                                            Hi Dan, Yes sorry that's the one!

                                            evolvingSEO 1 Reply Last reply Reply Quote 0
                                            • 1
                                            • 2
                                            • 1 / 2
                                            • First post
                                              Last post
                                            • Is robots met tag a more reliable than robots.txt at preventing indexing by Google?
                                              Bobbi_Tschumper
                                              Bobbi_Tschumper
                                              1
                                              7
                                              3.0k

                                            • Robots.txt advice
                                              Martijn_Scheijbeler
                                              Martijn_Scheijbeler
                                              0
                                              3
                                              105

                                            • Twitter Robots.TXT
                                              MarketingChimp10
                                              MarketingChimp10
                                              0
                                              5
                                              453

                                            • Have a Robots.txt Issue
                                              MattRoney
                                              MattRoney
                                              0
                                              5
                                              226

                                            • Help with Robots.txt On a Shared Root
                                              donford
                                              donford
                                              0
                                              10
                                              121

                                            • Robots.txt assistance
                                              theLotter
                                              theLotter
                                              0
                                              9
                                              280

                                            • Robots.txt
                                              TomRayner
                                              TomRayner
                                              0
                                              5
                                              137

                                            • Robot.txt error
                                              Rubix
                                              Rubix
                                              0
                                              13
                                              203

                                            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