Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Attachments not redirecting to parent pages #9316

Closed
SukcesStrony opened this Issue Mar 22, 2018 · 58 comments

Comments

Projects
None yet
@SukcesStrony
Copy link

SukcesStrony commented Mar 22, 2018

With one of the latest Yoast SEO versions (7.x), the attachment redirection function has changed, breaking some of the pages and not functioning as described in the Yoast Knowledge Base.

See this info: https://kb.yoast.com/kb/redirect-image-attachment-urls/

The options says “Redirect attachment URLs to the attachment itself?” and checking this box does exactly that.

Meanwhile, prior to Yoast 7.x (not sure which one exactly), the option basically was “Redirect attachment URLs to PARENT POSTS WHICH THEY ARE ATTACHED TO?”.

On the info page linked above, the description says: “Redirect will automatically redirect the attachment URLs to the parent post.” and there’s info on how to attach or detach attachment from posts.

This change in behaviour was therefore rather not intentional and is a bug. Further, websites which use image galleries to link to pages or posts which the attachments are attached to are now broken, as link point to images rather than posts.

Please correct this function so that it still redirects attachments to the parent posts which they are attached to.

In an ideal situation, users should have the following options:

  1. Redirect attachment URLs to parent posts which they are attached to (on by default AND TURNED ON IF THE CURRENT AND PREVIOUS REDIRECTION SETTING WAS TURNED ON, for backwards compatibility) – use the function which was used in Yoast 6.x
  2. Redirect attachment URLs to attachments themselves – use the function which was used in Yoast 7.x
  3. Do not redirect attachment URLs

Interlinked with forum post: https://wordpress.org/support/topic/bug-attachments-not-redirecting-to-parent-pages/#post-10101803

Best,
Chris

@maureen5

This comment has been minimized.

Copy link

maureen5 commented Mar 22, 2018

Our site is one of those affected by this latest Yoast upgrade, all my gallery page images not redirecting to post page of which there were 400 posts, have spent a week trying to find the problem with not a great deal of help from Yoast except offering to help and waiting for more than 24 hours for them to get back to you with not much help. The latest upgrade of Yoast if you can call it an upgrade, corrupted all of my meta descriptions on 400 pages, my sitemap redirected to the home page and Google Webmaster couldn't find them. As a paid member of Yoast this has been a very disappointing experience, especially with support which has come from three different people and almost robotic in reply, almost a week of downtime for my website.

@SukcesStrony

This comment has been minimized.

Copy link
Author

SukcesStrony commented Mar 23, 2018

As a temporary solution, turn off the "Redirect attachment URLs to the attachment itself?" option and use the following code in your functions.php file:

  add_action( 'template_redirect', 'sukcesstrony_attachment_url_redirect' );
  
  function sukcesstrony_attachment_url_redirect(){
	global $post;
	
	if ( is_attachment() && isset($post->post_parent) && is_numeric($post->post_parent) && ($post->post_parent != 0) ){
		wp_redirect( get_permalink( $post->post_parent ), 301 );
		wp_reset_postdata();
		exit();
	}

  }
@Gf177

This comment has been minimized.

Copy link

Gf177 commented Mar 29, 2018

Where do you recommend to put the code? At the bottom of the function.php file? Sorry, I don't know a lot about coding.

Also, on the wordpress forums another user said if the attachment media is posted in more than one blog post there is a redirect problem? Would that still exist or would it only redirect to the original or parent post, i.e. other blog posts could have the image, but they wouldn't be child of the parent or original post.

@Sandzee

This comment has been minimized.

Copy link

Sandzee commented Mar 31, 2018

Thank you SukcesStrony! I have applied this filter too in my functions.php file and now the attachment URLs are redirecting to parent posts but for my own info kindly tell me that yoast recommends we should redirect attachment URLs to the attachment itself but when I do this, my attachment sitemap gives 404, not found error and they say media is set to no index. So, how it is possible that we set it to yes and even then our images are indexed?

@SukcesStrony

This comment has been minimized.

Copy link
Author

SukcesStrony commented Mar 31, 2018

@Gf177 Doesn't matter that much where you put this code. Top of the functions.php file will be fine. If you want to keep things tidy, use the "Code Snippets" plugin to paste such code. An attachment can be "attached" to only 1 page or post (selected in the Media menu). Using the same image file in 2 different posts or pages doesn't affect redirecting. What can be troublesome is when an attachement is not attached to any post or page - then the redirect obviously won't work. But that's not a bug and can be fixed by attaching the attachment in the Media section.

@Sandzee Yoast SEO probably detects that the attachment page URLs are redirected and so there's no point in making a sitemaps file for them, as they are redirected anyway. Be sure to understand that the attachment sitemaps are sitemaps for dynamically generated URLs like:
domain.com/ATTACHMENT-FILE-NAME/ - this displays the attachment inside the theme (with the menu, sidebars, footers) and this is redirected and therefore not indexable
domain.com/ATTACHMENT-FILE-NAME.EXTENSION - this is the exact URL of the file and is NOT redirected, and is indexable
So, with the code above you're not redirecting the media file itself, just an URL which WP generates automatically for each media file.

@Sandzee

This comment has been minimized.

Copy link

Sandzee commented Apr 1, 2018

ok thank you.

@maureen5

This comment has been minimized.

Copy link

maureen5 commented Apr 3, 2018

@SukcesStrony

This comment has been minimized.

Copy link
Author

SukcesStrony commented Apr 3, 2018

@maureen5 One of the redirections (the one in the code above or the one introduced by Yoast) will take priority. Likely it will be the function run by Yoast as the one above has a default priority of 10.

@michaelbriantina

This comment has been minimized.

Copy link

michaelbriantina commented Apr 10, 2018

Please inform the customer of conversation # 342030 when this conversation has been closed.

@PatrickYoast

This comment has been minimized.

Copy link

PatrickYoast commented Apr 23, 2018

Please inform the customer of conversation # 344309 when this conversation has been closed.

@Pcosta88

This comment has been minimized.

Copy link
Contributor

Pcosta88 commented May 8, 2018

Attachment Pages get redirected to the Image File itself:

Set Redirect

1

See Attachment Page

2

Click on image and instead of being redirected from the attachment page back to the main url it goes to the image file

3

This is as expected from v7.0: https://yoast.com/yoast-seo-7-0/

@Pcosta88

This comment has been minimized.

Copy link
Contributor

Pcosta88 commented May 8, 2018

Please inform the customer of conversation # 357610 when this conversation has been closed.

@niki333niki

This comment has been minimized.

Copy link

niki333niki commented May 9, 2018

On one of my sites, this bug somehow reindexed all the attachment pages, shooting tons of low quality content out onto Google, bringing down both search ranks and traffic overall by the time I figured out what the hell happened and manually fixed the problem. Please inform me when this is addressed.

@remozseo

This comment has been minimized.

Copy link

remozseo commented May 17, 2018

I do have simply blog posts with featured image. I checked all settings and updated to the latest yoast version. The attachment re-direct does not work. All featured images are indexed with attachment pages. This is not good and a major bug.

Please help. This became a huge problem and simply irritates all users who trust the yoast brand over years. Thank you very much for all your help and fixing that problem! I really do appreciate it!

@Rob-Rychs

This comment has been minimized.

Copy link

Rob-Rychs commented May 22, 2018

Hey sort of half-relevant to this:

I have a few images that we changed the file name for OR the image has been deleted. Now those old image urls are returning 404s.

I've tried to add the old image url (with the .jpg extension) and redirect them to either the homepage or the newly named version of the image url using the latest version of Yoast's premium redirect manager but it doesn't seem to be working...

Any help would be appreciated!

@jack2345A

This comment has been minimized.

Copy link

jack2345A commented May 23, 2018

@SukcesStrony I looked again at the solution and actually there are two issues here. Just redirecting pages may not be the best solution.

The big issue is that the pages are already indexed - you need to remove them ASAP. How to remove these pages from the Google index:

You'll need to mark them as NOINDEX. Otherwise they'll stay in the google index for a VERY long time.
To do that - in the yoast plugin:

Redirect attachment URLs to the attachment itself? -> select NO
Show Media in search results? -> select No [super IMPORTANT}

This will add a noindex to all media pages and Google will remove them from the index. If you'll redirect these pages Google will miss the noindex so you must NOT redirect them.

But here's the catch once you marked "Show Media in search results?" to be No. They will not be in the sitemap so potentially Google wouldn't bother touching them and will not see the no index.

You need to submit a sitemap with these pages and change the mod date.

See this on how to deindex page quickly: https://www.seoinc.com/seo-blog/fastest-way-to-deindex-pages/

See this related article: https://www.bloggingglobal.com/attachments-pages-redirection-not-solving-problem-search-results/

After you've verified that all media pages have been removed you can redirect them if you want. But the noindex will prevent them from appearing the Google index.

I need to be quite clear and say that I completely lost trust with the YOAST SEO plugin. My site was in great shape but that change resulted in 4,000 thin content pages submitted to Google index. I now need to clean up the mess that they did and recover from the Google penalty that it caused. No QA in Yoast?
This is a massive loss in my side

@remozseo

This comment has been minimized.

Copy link

remozseo commented May 23, 2018

So how in heaven can we fix that?

@SukcesStrony

This comment has been minimized.

Copy link
Author

SukcesStrony commented May 23, 2018

@jack2345A thanks, I've fixed it.

@jdevalk

This comment has been minimized.

Copy link
Member

jdevalk commented May 25, 2018

I'm sorry some people got the wrong setting here during the upgrade. I can understand people are annoyed, as we also really didn't want this to happen.

There's not much for us to fix though: just set the first setting to "Yes" on the Media tab and attachment URLs no longer exist. That should take care of the problem in no-time. We will add a notice in an upcoming release, asking people to re-check this setting specifically when it's set to "No".

@jdevalk jdevalk closed this May 25, 2018

@jack2345A

This comment has been minimized.

Copy link

jack2345A commented May 25, 2018

@jdevalk - the advice that you give will put websites in more trouble,

You need to tell Google to NOINDEX these pages - they don’t need to be in the Google index. They need to get removed as fast as possible.

When setting to "Yes" the first setting Google will still keep these pages. There is really no point to redirect Google to the images as it serves no purpose and just loading the Google index with thin content as the images are already on the parent page. Google is smart enough to extract the images.

I am still at a loss why you made this change - this absolutely destroyed Google traffic. There was nothing wrong with the previous way that this was handled. It worked great for many years.

You obviously know that recovering from Google penalty is not a matter of "no-time". It may take months. Also many of these pages are orphaned pages so you really need to tell Google that something has changed by changing moddate in the sitemap.

Is anyone in the Yoast team really know what they are doing - this is such a basic error in your side. There is really no need in having these media pages in the Google Index. You are destroying the livelihood of hard working website owners.

@remozseo

This comment has been minimized.

Copy link

remozseo commented May 25, 2018

I agree with Jack.

So what’s the status on that issue? I am still confused 🤷‍♂️?

If we set it to “YES”, the media attachments will be still indexed as independent pages?

@Yoast:
Can you please clarify what the heck is going on here and can you be absolutely clear about necessary steps?

Appreciate it!

@maureen5

This comment has been minimized.

Copy link

maureen5 commented May 26, 2018

@jack2345A

This comment has been minimized.

Copy link

jack2345A commented May 26, 2018

@remozseo

See this article: about the Yoast SEO

It describes How Yoast SEO plugin for Wordpress will get you into Panda penalty by Google
What to do to recover
What to do with the Yoast SEO

https://www.seoblog.com/2018/04/wordpress-attachment-hurt-seo/

@jdevalk

This comment has been minimized.

Copy link
Member

jdevalk commented May 26, 2018

If you set the first setting on that page to Yes, ALL attachment pages are redirected. They no longer exist.

You can indeed also choose to set it to No, and then to noindex, but in the long run, the first solution is really the best.

@krunccrni

This comment has been minimized.

Copy link

krunccrni commented May 27, 2018

I set it to yes, but that pages are still showing in google index, it only redirect to picture. It was not like that before the update. Can you please tell me what to do to have the same amount of indexed pages like before the update?

@jdevalk

This comment has been minimized.

Copy link
Member

jdevalk commented May 27, 2018

The behavior changed, it now redirects to the image, not to the parent page. That's intended. It'll take some time for Google to reflect those changes.

The total number of indexed pages will drop, as the images do not count as indexed pages in google search console.

@krunccrni

This comment has been minimized.

Copy link

krunccrni commented May 27, 2018

ok, thanks!

@remozseo

This comment has been minimized.

Copy link

remozseo commented May 27, 2018

@Yoast:
with “Yes” it’s intended to direct to the image and not the page anymore?

How come?
How is that beneficial for google?
Why that change?

I guess the majority of us is just confused and we don’t understand why you changed it and how it will or should help with the rankings?

Why did you change it?

Could you please explain?

Thank you so much, appreciate it!

@jdevalk

This comment has been minimized.

Copy link
Member

jdevalk commented May 27, 2018

The rationale was simple: not all attachment pages have a parent post. Images you upload to your media library and don't attach to a post, for instance when you use them as header images, or in the customizer, or in lots and lots of other ways, don't have a parent. So all those attachment URLs couldn't redirect anywhere, didn't do anything, and therefore did still exist.

Next to that, if you use an image twice, it would redirect to the post it was connected to, regardless of where Google found the link. That's weird behavior.

To make the behavior simpler, faster and more reliable, redirecting to the image made much more sense. In general, you should not link to your attachment URLs. There's no real reason to. The important thing on that page is... The attachment. So redirecting the URL to the attachment made more sense.

@SukcesStrony

This comment has been minimized.

Copy link
Author

SukcesStrony commented May 27, 2018

I think that having all 3 options which I listed in the 1st post is best and doesn't break people's websites. One can easily use the built in WP gallery with redirecting attachments to parent posts, while keeping tabs on attachments, to make a gallery which has links to individual pages.

Could you implement the 3 options which I wrote about?

@jdevalk

This comment has been minimized.

Copy link
Member

jdevalk commented May 27, 2018

I could, but I won't, because I think 1 is not necessary. We already have 2 and 3: if you set it to no, we don't redirect. If you set it to yes, we redirect to the attachment. Adding more options than that is only confusing and let's be fair: this is really not something the majority of our 8 million users should be thinking about longer than 10 seconds or so. If you use attachment pages, you need this to be set to "no", otherwise, "yes" is perfect and adding more code to do a third option only slows everything down.

@HANNS22

This comment has been minimized.

Copy link

HANNS22 commented May 27, 2018

sir with this change your broken people business
How Working hard year long to get some traffic . after this new yoast seo plugin my website down for many keyword at position 3 to 15.
what was problem with older version? every bad have option to check NOINDEX attachment !
you are Know this was big mistake but they want to show are not incorrect !

you don't want to people lose faith in this yoast plugin . I think there are thousands of bloggers who think so like me and looking for alternative

@jdevalk

This comment has been minimized.

Copy link
Member

jdevalk commented May 27, 2018

@HANNS22: i'm sorry you've suffered from this, i truly am, but there's not much we can do now, and the new solution is truly better.

@remozseo

This comment has been minimized.

Copy link

remozseo commented May 27, 2018

hmm.. ok.. so the conclusion to all this confusion is:
Keep the settings to "YES", as it was before when using "YES" to re-direct to the attachment pages, correct?

@jack2345A

This comment has been minimized.

Copy link

jack2345A commented May 27, 2018

@HANNS22, @remozseo If you want to get (or keep) the Panda penalty feel free follow the advice of @jdevalk

But if you want to recover / avoid Panda - deindex these pages as fast as possible - this what I am doing now. It's a painful and long process. The Yoast SEO plugin caused a HUGE damage to my site.

After you deindex all pages - use the redirect code so that the attachment pages will get redirected to the parent post. NOT to the image as the image is already in Google (extracted form the post)

P.s if you decide to deindex make sure to submit a site map with a changed modedate. Once you set the Yoast plugin to noindex these pages - the sitemap will disappear which is terrible if these page are already in the Google index.

You'll need to wait at least 2-3 week until the pages are gone.

I suspect that there are thousands of sites (or even MUCH more) that got Panada penalty because of the changes in the Yoast SEO plugin. I've seen lots of comments in sites such as SEO Journal and in forums. People don't even know what hit them or why it happened. They don't really associate an upgrade in the Yoast SEO plugin to Panda penalty.

I'll drop this plugin as soon as possible.

image

@remozseo

This comment has been minimized.

Copy link

remozseo commented May 28, 2018

@jack2345A:
I see your point. I don't understand why Yoasts comments are totally the opposite?

@jdevalk:
I am really sorry yoast. Somehow your explanation does not make sense. If the settings are set to "YES", it means that the attachment pages are linking to the empty pictures. Therefore, a bunch of pictures will be indexed as pages.

But the problem is, those pages are not pages with any content on it. Those pages are basically blank pages with an image.

Can you explain why it should make sense to index a bunch of empty pages, with images on it?
It doesn't make any logical sense. And I do agree, following ack2345A comments.

You wrote and explained, if you are using attachment pages you need to set it to no. Well, isn't WordPress automatically creating attachment pages?

Is it really as complicated to write ONE CLEAR BLOG POST ABOUT THIS WHOLE CHAPTER?
A step by step statement, clear explanation, why you think your update should be fine as it is?

It is still unclear for a rookie WordPress user like me. When using your plugin, do you recommend now having those settings to YES, or to NO?

Thank you for taking the time and explaining it.
I guess a Video Tutorial + Statement would be even the best, considering you have 8 Million users.

Thank you for your efforts, appreciate it!

@jack2345A

This comment has been minimized.

Copy link

jack2345A commented May 28, 2018

@remozseo - reason is simple. Yoast invested lots of resources in making these changes in the plugin. And he is not going to revert them and cause more issues. This is his decision - take it or leave it.

The yoast SEO plugin is not the "god" of SEO - it's merely another tool in your toolbox that you can use. It doesn't really transform your site - it just makes your life simpler.

At the end of the day it's your site.

To me it doesn't make sense to have these pages as they don't add any value. If it's not adding value - why have it in the google index?? Why have thousands of indexed pages that don't add any value?

Yoast thinks differently but he doesn't own my site. And I sure not going to take his word after his changes put my site into Panda penalty.

@krunccrni

This comment has been minimized.

Copy link

krunccrni commented May 28, 2018

up he wrote "The total number of indexed pages will drop, as the images do not count as indexed pages in google search console." so I did set this option to yes, and already almost 200 pages are gone from google search results. Hope this works as I also saw a drop in traffic.

@jack2345A

This comment has been minimized.

Copy link

jack2345A commented May 28, 2018

@krunccrni - the general issue with that approach is that you are still submitting to the Google index pages that shouldn't be there (even if they get redirected to images).

Google's behavior today is to say something like: "I can see that you've submitted a page which is redirected it to image - I'll just mark this as an image and remove it from the index"

In the future Google may say: "you are submitting tons of junk I'll just put a penalty on your site"

My approach is - why take a chance. These links are not helpful and as such shouldn't be indexed in any form. I am also not going to take a chance with Yoast SEO plugin - in the future one of their programmers may make a mistake and disable this redirection to image. Or someone in the Yoast team may suddenly decide that "things should be changed" and you are back to square one.

@remozseo

This comment has been minimized.

Copy link

remozseo commented May 28, 2018

@jack2345A indeed, that makes sense. I hear you. The questions is: How can you make sure, that the attachment pages from WordPress (which obviously have zero value and just contain images) aren't getting indexed by google?

How can you avoid it when using WordPress?

@jack2345A

This comment has been minimized.

Copy link

jack2345A commented May 28, 2018

@remozseo - this is simple: Mark the attachment pages in Yoast as noindex but DON'T redirect to Image. (Also important to remove existing pages).

After you have all these pages out of the Google index, use the code the suggested by @SukcesStrony to redirect the attachments page to parent page.

Once you have the attachment pages as noindex - Yoast SEO will not generate sitemaps for them so Google will not know about them.

Assuming something will break in Yoast SEO - in the future you have the redirection to parent post hard coded (as a safety net outside of Yoast). So if Yoast decides to tell Google to index the attachment pages - they'll get redirected to the post which will not change anything.

I am also reminding myself to regularly check Google console for any change in the number of indexed pages and look at any spikes.

Essentially I am trying to mitigate any future bug / changes in the Yoast plugin. (I just lost trust in this plugin).

It is very much aligned with what this person suggests:
https://www.seoblog.com/2018/04/wordpress-attachment-hurt-seo/

@remozseo

This comment has been minimized.

Copy link

remozseo commented May 28, 2018

@jack2345A this is super interesting. Also thank you so much for all your explanation.

I am still a newbie to WordPress. I tried to google it, but I was not able to find any clear answer to that. How in heaven, can you find all your attachment pages?

I tried to search within the MEDIA-TAB. But all I can find are MEDIA files, unattached.
image

Are the unattached media files the one we should attach to a page?
So yes... I have no clue how to find all attachment pages... lol;

Uff.... I guess I do have a total black out right now. Totally confused. Is there anywhere a simply step by step guide I could follow?

Thank you so much for all your help folks - you rock - cheers!

@jdevalk

This comment has been minimized.

Copy link
Member

jdevalk commented May 29, 2018

We're working on a post about this topic and a better solution to get rid off attachment URLs in the search results, if you're truly suffering from it. Lots of moving parts but we're working as fast as we can.

@pirlusa

This comment has been minimized.

Copy link

pirlusa commented May 29, 2018

Hi, I´m not an expert in these things and it took me a while to realise it was a problem caused by Yoast plugin and not by myself.
I´m going to uninstall Yoast because I couldn´t figure out what was happening, and unless I become a programmer I´ll never do that fast enough to avoid a problem in my site.
The first notice I had was a +453% in bounce rate, IN A WEEK. I assumed I was writing content that people found irrelevant. Haha.
I googled my site and guess what, instead of my post people was redirected to A BLANK PAGE WITH JUST AN IMAGE. Not a 100% irrelevant one, but it was an image supossed to be within the blog content, they are meant to work adding info to your post. They can´t BE informative without a post, they don´t stand alone.
I don´t know who had the idea of "hey, we don´t know where to redirect this image because it´s attached to 2 posts, let´s make it redirect to itself" WTF people!! And since a developer in this thread admitted to think it was ok...I´m pretty astonished.
The multiple attachment was not my issue since I had certain images for certain posts. But the logical option is to redirect them to 1) all the parent posts to which they are attached, ordering them by relevance / matching with the user search. (the best one IMHO)
2) the parent post it was first attached, or the last one, aka, more recent parent post or first parent post with that image attached (a dated sort of choice)
3) NO INDEX. Please, don´t index them at all!!!
I´m now de-indexing each one manually with URL removal tool in Search Console. I´ve already marked them as Noindex, I´ve submitted a new sitemap without those URLs, I´ve changed the default image-url-link with "none" in wordpress, I´m planning to write that code given in this thread (thanks guys!) in my ftp (a task that FREAKS ME OUT since I repeat I´m not a code reader, less a writer, even a copypaster!) but you know what, those infame blank pages are still showing in my search results.
Yoast messed up totally the way my blog appears in Google, it doesn´t show the snippet under the posts, just unrelated tags or portion of texts, and searching only my blog (without keywords) throws obsolete tags below (I´ve deleted them once month ago). And I always had the option "Show tags" disabled!! Now it turned to show obsolete categories AND obsolete tags. A disaster!! Even if I selected no-index in each one.
I´m still trying to figure out what I should do to appear fine as before Yoast got installed in my Wordpress, an action I truly regret. A friend of mine says it goes to a blank page when he googles my site (he has Opera browser in his phone) and I suspect it´s because somehow the image pattern of my theme is getting indexed or something as crazy as that is happening. All of these issues were non existent before. I don´t know if everything is due to Yoast, but this mess is bad enough.
Besides that, the SEO optimization is just giving the author certain recommendations (where to put a keyword, how many times it should appear, etc), I´ll write those recommendations down and use the old and tested Word count tool in a word document instead of jeopardizing my site, my traffic, my Google appearance, and my hosting resources!!
Sorry but you shouldn´t mess up with Google guys, most of (if not all) our income as bloggers comes from Adsense.
I guess I´m lucky for not being punished by Google just by a prior and non advisable thing I did: instead of attaching images in Wordpress library, I used to just embed a link from my Instagram profile in my wordpress posts. That way my site was extremely low and each post weighted 15 MB, but I avoided the magic creation by WP and indexation by Yoast of hundreds of thin content pages. Also I used to "hotlink" my own images from my own old Blogger blog, I don´t know if it is a good practice, but since I´m the owner of both domains and Google is informed about that, it isn´t punishing me (unless it is and I´m not aware).
Sorry my English and my non programming language, I barely understand these things and I had to learn as much as I could in 2 days. I´ll welcome any advice!

@sanderkie

This comment has been minimized.

Copy link

sanderkie commented Jun 3, 2018

I have set my Media redirect to YES.

As a result, the first 5 results in google are IMAGES.
The product page is actually pushed down to second page, no mans land.

Apparently now google thinks the 5 page images are more important than the product page itself, completely destroying any SEO results as everybody clicks away the attachment page.


We can now start doing all kinds of things. Like making them NOINDEX or start redirecting all the images manually.
YoastSEO is taking too long to come up with a proper solution. What would you suggest doing in the meantime? The temp solution might do more harm then good.

@bc1974A

This comment has been minimized.

Copy link

bc1974A commented Jun 3, 2018

I've gone with the workaround mentioned by @jack2345A referencing this post: https://www.seoblog.com/2018/04/wordpress-attachment-hurt-seo/, using method 4.

I'll give Yoast a chance but agree this was a bit of a shocker and has cost me and my client a lot of money, frustration and rankings trying to work it out, and am concerned something like this will hurt it again in future.

Seems a simple thing for Yoast to do what method 4 does, to check the scenarios it mentions in https://www.seoblog.com/2018/04/wordpress-attachment-hurt-seo/.

@jack2345A

This comment has been minimized.

Copy link

jack2345A commented Jun 4, 2018

Hi @bc1974A - just make sure that Google removes the pages first before you do the redirect. (at least this is the recommendation). If it's just a small number of URL's the quickest option would be to use Google console to Remove the URL.
The issue that I found is that Google is really slow in crawling these pages again and removing them. These are low value pages and Google doesn't spend resources on that. Really hard to wait when traffic has plummeted.
I still think that these URL's shouldn't be in the Google index (even no redirect to image)

@sanderkie

This comment has been minimized.

Copy link

sanderkie commented Jun 4, 2018

A final recommendation by the YOAST team would be highly appreciated.

@jack2345A

This comment has been minimized.

Copy link

jack2345A commented Jun 5, 2018

Hi @sanderkie - Yoast released his "purge" plugin. Strictly speaking it doesn't purge anything from the Google index. It just marks the attachment pages with 404 and submit sitemap to Google. But Google will decide according to its own schedule when to remove these pages. You'll notice that Yoast says that you need to have this plugin installed for a few months.

So not really a purge - it's just tells Google that the pages are gone.

If you want a quick purge just use the Remove URL from your Console.

@sanderkie

This comment has been minimized.

Copy link

sanderkie commented Jun 5, 2018

Thank you for the heads up @jack2345A . I would appreciate it of @jdevalk would comment on this and the right steps to take.

As a wrong step might take many months to correct (as we can see now); I would rather do it in align with Yoast. Otherwhise we might need to move towards a different SEO approach as Yoast lost a lot of credibility with this move.

Joost, could you share your thoughts?

@michielheijmans

This comment has been minimized.

Copy link
Member

michielheijmans commented Jun 5, 2018

First: is it the attachment pages that are hurting you? If it's just a number of 'em, this is unlikely.

Joost did a write-up with more background and our fix: https://yoast.com/media-attachment-urls/

Please note that the plugin creates a 410 - not a 404 - for the attachment page, but will still show the image. Google needs to find these 410s first to be able to get rid of them from their index. Meanwhile, your site needs to function as intended, that is why we choose this solution and aligned that solution with Google. They agree that this is the fastest way. The plugin affects the attachment pages and the way they are handled, the rest remains untouched. See article for more. I hope that clarifies things.

@sanderkie

This comment has been minimized.

Copy link

sanderkie commented Jun 5, 2018

Thank you @michielheijmans; I already read that page (it came up during the last Yoast update).

When I am googling for the exact name of a product, the first 2 search hits are still attachement-urls. By now they are redirected to the image, but that still makes them completely irrelevant causing 100% drop off and 0% conversion rate.
The actual product page is not even listed.

So that 'little mistake' does seem to have a negative impact, no matter what Google says.

Note: this is a relative new product that was probably introduced after this bug occurred. Older products are thankfully still listed as usual.

@jack2345A

This comment has been minimized.

Copy link

jack2345A commented Jun 5, 2018

@sanderkie - it deson't matter what Google says, it matters what Google DOES. Sometimes what google says and what google does is completely different.

Google wants any indexed content to be valuable to the reader.

Attachment pages or paginated pages of home page - do NOT provide any value. They should NOT be in any way or form in the Google index.

This is what Yoast doesn't understand - Google does NOT and will NOT release any information that will help you to reverse engineer its algo. Yoast thinks that he knows it all based on what he talks with the "google guys". But he completely lost the connection to reality.

@pirlusa

This comment has been minimized.

Copy link

pirlusa commented Jun 8, 2018

I´ve updated Yoast and installed the Search Index Plugin but the problem was still around. I fixed it with a plugin which redirects 404 to 301, at least people get redirected to some post or category instead of a dumb attachement.

@nfranver

This comment has been minimized.

Copy link

nfranver commented Dec 11, 2018

@jack2345A I´m arriving late to the post with the same issues that you all faced a couple of months ago.
I just want to know how is your site after all these months? Have you improved or recovered your rankings?

We are a big site, and because we have 40.000 images, our traffic drop more than 60%. We are still trying to recover, but in the last month and a half, nothing happened.

We installed the yoast plugin to fix the bug but we are now experiencing +35K crawl errors in GSC. That is affecting us because we are seeing a constant drop in visits and PV.

I want to ask you if you are still keeping the redirects? and if you faced crawl errors. Any suggestion to fix them? Waiting is not a possiblity since we lost revenues, rankings and we are struggling to reverse this situation.

Thanks for your help, all the updates are very welcome :) @SukcesStrony

@jack2345A

This comment has been minimized.

Copy link

jack2345A commented Dec 15, 2018

@nfranver - my site hasn't recovered - in fact things are getting much worse. I think that recovering from such issue can take many many months. I coded all these pages to noindex and Google removed them 5 months ago but rankings didn't recover. In the past 5 months Google had many more algo updates that made things a lot worse for my site. I am getting a lot more traffic from Bing than Google at the moment.... This is absolutely bizarre as the site has been is good terms with Google in the past few years and I've constantly worked on improving quality.

The errors that you get are just because these pages have been removed so google can't find them - you can ignore these errors.

I lost a LOT of revenue as well but there is nothing much I can do apart of waiting and making more changes to the site.

There was also a HUGE Google update in August.

Did you check the links pointing to your site - I've noticed a lot of spammy links that I've disavowed last month.

Did anyone else manged to recover?

@cezars

This comment has been minimized.

Copy link

cezars commented Feb 16, 2019

Any new update on how to fix this the best way possible. From yoas you don`t get any help as i try like many others wen i discover the problem that was made by him afecting millions of websites.. Having 17.000+ post and from that update i keep trying to recover...

Regards

@nfranver

This comment has been minimized.

Copy link

nfranver commented Feb 19, 2019

@cezars We've seen a recover since the last couple of weeks.
We haven't recover all the traffic, but it has improved considerably.

This is what we did:

  1. Install the bug plugin form Yoast
  2. Erase all the attachment URL's in WMT
  3. Review links pointing to our site and send a disavow txt to Google

It took us 5 months. Still trying to recover all the visits. But at least we changed trends.

The question now is how to eliminate +35K errors in Google Search Console. Basically Yoast sitemap keeps sending all those URL's, that's why we haven't been able to reduce them.

We are considering going back to Google sitemp. But is is still in consideration. Does anyone uninstalled Yoast debug plugin? @jack2345A

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.