2

To improve my websites' user experience, I want to optimize site speed, as well as search engine ranking.

Google stated that Improving web speed can benefit ranking in search engine results, but apart from that, search engine optimization seems hard to measure. Most search engine optimization advice seems to be rather anecdotal than based on facts and measurements.

Following advice in a Lighthouse web page speed report, I started to "use a Content Delivery Network (CDN)" by deploying to Netlify. As I understand, content delivery networks help to reduce connection and transfer time by providing content from a nearby mirror server. Many also offer automated image optimization, reducing file size.

Deploying a website on Netlify with the asset optimization feature activated, images are automatically hosted on a CDN, rewriting image URLs to CloudFront subdomains instead of the original website domain.

During talks and discussions, web developers and search engine optimization professionals claimed that using CDN domains will harm efforts to make a website's images rank high in image search results. But they could not cite factual information to prove their claim.

As discussed earlier on StackOverflow, providing redirects to the new URLs should prevent a temporary drop from image search results.

It is not clear to me if there might be any other disadvantage of hosting images on a CDN. I asked the google community how to ensure image search optimization when hosting on a content delivery network, but I did not get an official statement from Google so far.

Please help me to solve this dilemma based on facts and evidence.

5
  • I already posted the same question on StackOverflow, but instead of any helpful answer received a downvote for being offtopic there. Sorry. Feb 5 at 12:09
  • CDNs don't usually offer mirror servers. Rather they offer nearby caching reverse proxies. A mirror server has a copy of your entire site. A caching proxy fetches documents from your site as they are requested by users and stores them for a time period to be used if they are requested again. There are CDN mirror services, but they are far less common than the proxies. Feb 5 at 13:37
  • When your images are on the CDN, what are their URLs? Are they still on your domain, like using a subdomain, or are they hosted on a different domain for the CDN? Feb 5 at 13:39
  • @StephenOstermiller This original image URL serves the image from my website’s domain and with the exact path I intended it to be and to be indexed by image search: ingo-steinke.de/img/ingo-steinke-portrait-2020.jpg This is the image URL used with asset optimization: d33wubrfki0l68.cloudfront.net/… Feb 5 at 13:41
  • The subdomain problem seems to be a problem only when using CloudFront via Netlify. If I had full control over the CDN, I would use a subdomain of my original domain, like images.ingo-steinke.de, and this is what I will probably do some time instead of using although I did like its easy deployment triggered by pushing to Github. Feb 5 at 13:46
2

Having the image URL change to the CDN's domain is problematic for image SEO. You say that an example image URL is now https://d33wubrfki0l68.cloudfront.net/1cc7c854a3e57dd05ecaf7f6153d5736820f3d76/58b8a/img/ingo-steinke-portrait-2020.jpg while the original URL on your site is https://www.ingo-steinke.de/img/ingo-steinke-portrait-2020.jpg

  1. The image is no longer hosted on your domain.

    • This makes it much harder for Google to associate it back to your site reliably. If another site hot-links the image, it is just as likely as your site to appear in the image search results as the page hosting that image.
    • If you stop using the CDN your image URLs will all break and you will have no way to preserve the SEO of those images in image search.

    Rather than use a subdomain of the CDN, it would be better to use a subdomain of your own site. Assigning images.example.com to point to the CDN would alleviate many of the SEO concerns. Some (but not all) CDNs allow you to do so. For SEO, I would not use a CDN that hosts any of my content under its own domain.

  2. The image is still available on its old URL on your own site.

    • This creates duplicate content and splits your SEO between the two URLs. Google will only index one of the two URLs which are now competing with each other.
    • If your images had been ranking in image search before, they are likley to lose all their rankings. They are no longer linked from your site, so they have lost all their PageRank. Google will eventually start indexing the new URLs, but it could take weeks or months.

    When you change URLs, even for images, you should implement "301 Permanent" redirects from the old URLs to the new URLs. This will allow Google to preserve rankings from the old URLs. Because the old URLs are being used by the CDN as your origin server, you would need to use some special server side logic to allow the CDN to fetch the images, but return redirects for other clients such as Googlebot.

    It doesn't help that the CDN has added gibberish to the URL (probably a content hash). That means that redirecting the old URLs will be a one-by-one task rather than a simple rule for all the images. It would be better to find a CDN that allows you to use the same URL path that you used for the old URLs.

Images from CDNs can and do rank in Google image search. They and your site may get slightly better SEO from the performance benefits of the CDN. However, changing the image URLs for the CDN initially kills SEO. Now that the images are hosted on CDN URLs, you have vendor lock in with that CDN if you want to preserve image SEO when migrating away from that CDN.

1

You could probably find some decent stats on this, but I think you've basically arrived at the right answers yourself.

Yes, SEO is anecdotal, and you have the right idea about CDNs. I think it makes no difference to Google if you're properly redirecting and following best practices on that.

Search for something in Google Images. Depending on search term you'll probably see CDNs serving most/all of the top ranked images from a different domain and subdomain.

Amazon, YouTube, large online stores, Pinterest, etc. At a certain point, the anecdotal evidence adds up to something here. Using a CDN isn't punished by Google, and the faster connect + download speeds will boost your ranking slightly (and possibly more in the near Google update).

3
  • "Yes, SEO is anecdotal" expresses my past experience and probably yours as well, but it is, itself, an anecdotal claim. I had hoped in times of tools like Lighthouse, there would be more factual evidence to SEO topics than there used to be? Feb 5 at 13:40
  • There is plenty of good SEO information out there that is based on experiments and larger scale tests. There are also a lot of anecdotes and speculation. It is even more complicated because many SEO agencies tout the SEO advice for which they can charge for services. Google also offers SEO advice, but they also tend to have their own interests in mind, their advice is rarely optimal, and often somewhat misleading. Feb 5 at 13:45
  • I don't think it's any easier now to find solid evidence for SEO questions (but it does exist). It's a big business, so when you search your SEO question, it shows you SEO content as a result. And Google is still Google. It only explains what it wants to explain. Web Vitals and links from here may help: web.dev/vitals
    – Trich
    Feb 5 at 14:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.