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. Technical SEO Issues
    4. Hide messenger for crawlers

    Hide messenger for crawlers

    Technical SEO Issues
    2 2 45
    • 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.
    • rogier_slag
      rogier_slag last edited by

      At Magnet.me we are using Intercom to communicate with our users. This means that we are actively adding javascript code which will load the Intercom javascript on each page, and render the button afterwards.

      However, this button has no value for crawlers, and slows the page down as the javascript is big and fairly slow. Therefore I considered to ship some code which disables this button, such that performance would improve. To give a ball pack estimate, the buttons javascript is around 3x bigger than the actual entire react application...

      Unfortunately this would result in giving users and crawlers slightly different content on the page. I'm unsure about the possible SEO impact:

      • Would Google mark the page as faster due to less resources to load?
      • Or would it penalize the page for showing slightly different content to users and search engines?
      1 Reply Last reply Reply Quote 0
      • effectdigital
        effectdigital last edited by

        In general, I don't think that this is a great idea. Although Google does meter out crawl-allowance, Google also wants a realistic view of the pages which it is crawling. Your attempt at easing the burden of Google's crawl-bots may be seen as an attempt to 'fake' good page-speed metrics, for example (by letting Google load the web-page much faster than end users). This could cause some issues with your rankings if uncovered by a 'dumb' algorithm (which won't factor in your good intentions)

        Your efforts may also be unrequired. Although Google 'can' fire and crawl JavaScript generated elements, it doesn't always do so and it doesn't do that for everyone. If you read my (main) response to this question, you'll get a much better idea of what I'm talking about here. As such, the majority of the time - you may be taking on 'potential' risk for no reward

        Would it be possible to code things slightly differently? Currently you state that this is your approach:

        "This means that we are actively adding javascript code which will load the Intercom javascript on each page, and render the button afterwards"

        Could you not add the button through HTML / CSS, and bind a smaller script to the button which then loads the "Intercom javascript"? I am assuming here that the "Intercom javascript" is the large script which is slowing the page(s) down. Why not load that script, only on request (seems logical, but also admit I am no dev - sorry)? It just seems as though more things are being initiated and loaded up-front than are really required

        Google want to know which technologies are deployed on your page if they choose to look, they also don't want people going around faking higher page-speed loading scores

        If you really want to stop Google wasting time on that script, your basic options would be:

        • Code the site to refuse to serve the script to the "googlebot" user agent
        • Block the script in robots.txt so that it is never crawled (directive only)

        The first option is a little thermonuclear and may mean you get accused of cloaking (unlikely), or at the least 'faking' higher page-speed scores (more likely). The second option is only a directive which Google can disregard, so the risks are lower. The down-side is that Google will pick up on the blocked resource, and may not elevate your page-loading speed. Even if they do, they may say "since we can't view this script or know what it does, we don't know what the implication for end-users is so we'll dampen the rankings a little as a risk assessment factor"

        Myself, I would look for an implementation that doesn't slow the site down so much (for users or search-bots). I get that it may be tricky, obviously re-coding the JS from Intercom would probably break the chat entirely. Maybe though, you could think about when that script has to be loaded. Is it really needed, on page-load, all the time for everyone? Or do people only need that functionality, when they choose to interact? How can you slot the loading of the code into that narrow trench, and get the best of both worlds?

        Sorry it's not a super simple answer, hope it helps

        1 Reply Last reply Reply Quote 1
        • 1 / 1
        • First post
          Last post
        • Hide mobile content element
          MarcelMoz
          MarcelMoz
          0
          3
          107

        • Block bad crawlers
          GeoffKenyon
          GeoffKenyon
          0
          4
          326

        • SEOMoz Crawler vs Googlebot Question
          SteveTheWoodsman
          SteveTheWoodsman
          0
          2
          289

        • Hiding sub directory from a url string
          omega
          omega
          0
          5
          2.8k

        • How does your crawler treat ajax links?
          0
          1
          427

        • Crawler Stats
          Stevej24
          Stevej24
          0
          8
          508

        • Hiding text with Javascript and a more button
          dmac
          dmac
          0
          3
          726

        • Mobile SEO or Block Crawlers?
          Michael_Martin
          Michael_Martin
          0
          2
          981

        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