Support » Plugin: Jetpack - WP Security, Backup, Speed, & Growth » Removing WordPress attachment pages from jetpack galleries

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Contributor Lisa Schuyler


    Hi @miguelgaton!

    I’m not clear on what you are asking. Are you wanting the gallery to not open a large image size? Or you want the link to the full size from that carousel view removed?

    Or something else entirely?

    Thread Starter miguelgaton


    Hello @lschuyler,

    I want to keep the same fonctionality, I only want to remove attachment pages from the HTML sourcecode generated by the gallery to avoid googlebot can discover and follow all these “unnecesary urls”.

    Thread Starter miguelgaton



    The sourcecode of the gallery is something like:

    <div data-carousel-extra='{"blog_id":1,"permalink":"https:\/\/\/prueba-mazda-mx-5-rf\/"}' id="gallery-2" class="gallery galleryid-224616 gallery-columns-3 gallery-size-thumbnail"><dl class="gallery-item"><dt class="gallery-icon landscape">
    				<a></strong>"><img width=&quot;150&quot; height=&quot;150&quot; src=&quot;; class=&quot;attachment-thumbnail size-thumbnail&quot; alt=&quot;Prueba Mazda MX-5 RF&quot; srcset=&quot; 150w, 300w&quot; sizes=&quot;(max-width: 150px) 100vw, 150px&quot; data-attachment-id=&quot;224709&quot; <strong>data-permalink=""</strong> data-orig-file="" data-orig-size="830,553" data-comments-opened="1" data-image-meta='{"aperture":"5.6","credit":"","camera":"NIKON D3300","caption":"","created_timestamp":"1485338015","copyright":"","focal_length":"18","iso":"400","shutter_speed":"0.008","title":"","orientation":"1"}' data-image-title="prueba-mazda-mx-5-rf-40" data-image-description="" data-medium-file="" data-large-file="" /></a>
    			</dt></dl><dl class="gallery-item"><dt class="gallery-icon landscape">
    				<a href=""><img width="150" height="150" src="" alt="Prueba Mazda MX-5 RF" /></a>

    Here you can see all WordPress attachment pages like data-permalink=" and data-permalink="", so when googlegot access to this post it can see and follow all attachment pages. We have around 200.000 images on this site so googlebot has to follow 200.000 url’s only to see a 301 redirect, that’s not good for google.

    We want to optimize crawler bugdet and for this reason I need to avoid googlebot can discover attachment pages. Now I think googlebot can only discover attachment pages in jetpack galleries.


    Plugin Author Jeremy Herve


    Jetpack Mechanic 🚀

    Jetpack adds that information to be able to display a Carousel view when you click on the images. If you’d rather not display any links, I would recommend that you deactivate Jetpack’s Carousel module on this page:

    Once you’ve done so, you will also want to make sure your gallery options are set not to link to attachment pages.

    I hope this helps.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Removing WordPress attachment pages from jetpack galleries’ is closed to new replies.